You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 11, 2021. It is now read-only.
A Block is a data structure available on this module.
30
32
31
-
## Usage
33
+
#Installation
32
34
33
-
```bash
34
-
$ npm i ipfs-blocks
35
+
## npm
36
+
37
+
```sh
38
+
> npm i ipfs-blocks
35
39
```
36
40
37
-
```javascript
38
-
constipfsBlocks=require('ipfs-blocks')
41
+
## Use in Node.js
42
+
43
+
```JavaScript
44
+
var ipfsBlocks =require('ipfs-blocks')
45
+
```
39
46
47
+
## Use in a browser with browserify, webpack or any other bundler
48
+
49
+
The code published to npm that gets loaded on require is in fact a ES5 transpiled version with the right shims added. This means that you can require it and use with your favourite bundler without having to adjust asset management process.
50
+
51
+
```JavaScript
52
+
var ipfsBlocks =require('ipfs-blocks')
53
+
```
54
+
55
+
## Use in a browser Using a script tag
56
+
57
+
Loading this module through a script tag will make the `Unixfs` obj available in the global namespace.
0 commit comments