Skip to content

RangerMauve/resolve-hyper-structure

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

resolve-hyper-structure

Library for resolving a hyper:// URL to a hypercore-protocol based data structure

How it will work (TODO)

  • Check for a hypercore header in the 0 index.
  • If the length is 0, wait for a peer to get some data? (MAYBE)
  • If you get some data and 0 isn't a header, assume it's a regular hypercore
  • Try to map the header to the datastructure and pass in the hypercore
  • Assume that hypertrie with a metadata of 64 bytes is a Hyperdrive
  • Try to get this merged to make life easier.-

API

const resolveHyperStrucutre = require('resolve-hyper-structure')

const {type, metadata} = await resolveHyperStrucutre(hypercore)

About

Library for resolving a `hyper://` URL to a hypercore-protocol based data structure

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published