New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@did-core/did-cbor

Package Overview
Dependencies
Maintainers
2
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@did-core/did-cbor

``` npm i @did-core/did-cbor --save ```

0.1.1-unstable.15
latest
Source
npm
Version published
Weekly downloads
1
-50%
Maintainers
2
Weekly downloads
 
Created
Source

@did-core/did-cbor

npm i @did-core/did-cbor --save

Usage

import { factory, DidDocument } from '@did-core/data-model';
import { representation } from '@did-core/did-cbor';

const didDocument: DidDocument = factory.build({
  entries: {
    // @context is required for use with jsonld verifiable credentials
    // but technically optional here
    '@context': 'https://www.w3.org/ns/did/v1',
    id: 'did:example:123',
  },
});

const representation: Buffer = await didDocument
  .addRepresentation({ 'application/did+cbor': representation })
  .produce('application/did+cbor');

FAQs

Package last updated on 30 Jun 2021

Did you know?

Socket

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