Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/liammartens/json-dereference


https://github.com/liammartens/json-dereference

Last synced: 11 days ago
JSON representation

Awesome Lists containing this project

README

        

# json-deref
This is a very basic library to dereference JSON objects. It supports both local and remote references, but only supports root references (relative referencing is not supported).

## Example
```js
import { dereference } from 'json-deref';

await dereference({
obj: {
value: {
$ref: 'https://example.com/schema#/value',
},
},
}, {
loadSchema: async (url) => ({
value: 500,
})
})
```