Socket
Socket
Sign inDemoInstall

multicodec

Package Overview
Dependencies
1
Maintainers
3
Versions
45
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    multicodec

JavaScript implementation of the multicodec specification


Version published
Weekly downloads
413K
decreased by-21.88%
Maintainers
3
Install size
341 kB
Created
Weekly downloads
 

Changelog

Source

0.5.7 (2019-12-22)

Bug Fixes

  • name table not hex encoded (88bf273)
  • remove unused table file (f3766e5)

<a name="0.5.6"></a>

Readme

Source

js-multicodec

Travis CI Coverage Status

JavaScript implementation of the multicodec specification

Lead Maintainer

Henrique Dias

Table of Contents

Install

> npm install multicodec
const multicodec = require('multicodec')

Usage

Example


const multicodec = require('multicodec')

const prefixedProtobuf = multicodec.addPrefix('protobuf', protobufBuffer)
// prefixedProtobuf 0x50...

// The multicodec codec values can be accessed directly:
console.log(multicodec.DAG_CBOR)
// 113

// To get the string representation of a codec, e.g. for error messages:
console.log(multicodec.print[113])
// dag-cbor

API

https://multiformats.github.io/js-multicodec/

multicodec default table

Updating the lookup table

Updating the lookup table is done with a script. The source of truth is the multicodec default table. Update the table with running:

node ./tools/update-table.js

Contribute

Contributions welcome. Please check out the issues.

Check out our contributing document for more information on how we work, and about contributing in general. Please be aware that all interactions related to multiformats are subject to the IPFS Code of Conduct.

Small note: If editing the README, please conform to the standard-readme specification.

License

MIT © 2016 Protocol Labs Inc.

Keywords

FAQs

Last updated on 22 Dec 2019

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc