# @ipld/dag-cbor

[![codecov](https://img.shields.io/codecov/c/github/ipld/js-dag-cbor.svg?style=flat-square)](https://codecov.io/gh/ipld/js-dag-cbor)
[![CI](https://img.shields.io/github/actions/workflow/status/ipld/js-dag-cbor/js-test-and-release.yml?branch=master\&style=flat-square)](https://github.com/ipld/js-dag-cbor/actions/workflows/js-test-and-release.yml?query=branch%3Amaster)

> JS implementation of DAG-CBOR

# Install

```console
$ npm i @ipld/dag-cbor
```

## Browser `<script>` tag

Loading this module through a script tag will make its exports available as `IpldDagCbor` in the global namespace.

```html
<script src="https://unpkg.com/@ipld/dag-cbor/dist/index.min.js"></script>
```

## Spec

The [`dag-cbor` specification is in the IPLD specs repo](https://github.com/ipld/specs/blob/master/block-layer/codecs/dag-cbor.md).

# API Docs

- <https://ipld.github.io/js-dag-cbor>

# License

Licensed under either of

- Apache 2.0, ([LICENSE-APACHE](https://github.com/ipld/js-dag-cbor/LICENSE-APACHE) / <http://www.apache.org/licenses/LICENSE-2.0>)
- MIT ([LICENSE-MIT](https://github.com/ipld/js-dag-cbor/LICENSE-MIT) / <http://opensource.org/licenses/MIT>)

# Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
