0.0.6 • Published 4 years ago

unixfsv1-part-importer v0.0.6

Weekly downloads
1
License
(Apache-2.0 AND M...
Repository
-
Last release
4 years ago

Usage

importer(parts)

This method returns `@ipld/block](https://github.com/ipld/js-block) instances for only thedag-pbnodes the UnixFSv1 importer creates. Since you are passing in the lengths and lengths of theraw` blocks those are not returned.

const importer = require('unixfsv1-part-importer')
const CID = require('cids')
const raw = new CID('mAVUSIO7K3sMLqZPsJ/6SYMa5HiHBaj81xjniNYRUXbpKl/Ac') // CID of a raw node
const parts = [
  { cidVersion: 1, size: 138102, cid: raw }
]
const blocks = await importer(parts) // contains only the dag-pb nodes for unixfs
0.0.6

4 years ago

0.0.5

4 years ago

0.0.4

5 years ago

0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago

0.0.0

5 years ago