cloudevents-schemas

node library project template

Usage no npm install needed!

<script type="module">
  import cloudeventsSchemas from 'https://cdn.skypack.dev/cloudevents-schemas';
</script>

README

Node Lib Template

node library project template

license release super linter test semantic

This package publishes all versions of the CloudEvents Schema JSON spec

.
├── LICENSE
├── index.js
└── schemas
    ├── latest
    │   └── spec.json
    └── 1.0
        └── spec.json

How

// directly require the JSON schema files
const latest = require('cloudevents-schemas/schemas/latest/spec.json')
const versioned = require('cloudevents-schemas/schemas/1.0/spec.json')

// require all the schemas in one object
const schemas = require('cloudevents-schemas')

/** schemas is an object with the following shape:
  {
    latest: ...
    1.0: ...
  }
*/

Author: Ahmad Nassri • Twitter: @AhmadNassri