【文件属性】:
文件名称:json-api-merge:JSON格式
文件大小:152KB
文件格式:ZIP
更新时间:2021-03-29 17:11:59
JavaScript
JSON API合并
json-api-merge是特定于JSON:API的冗余复制算法,用于将包含的资源合并到原始数据中。
入门
安装
npm i json-api-merge
或者
yarn add json-api-merge
用法
const jsonApiData = {
data : {
id : 1 ,
type : 'resource' ,
attributes : {
name : 'Resource name' ,
} ,
relationships : {
related : {
data : {
id : 2 ,
type : 'related_resource' ,
} ,
} ,
} ,
} ,
【文件预览】:
json-api-merge-master
----.eslintrc(1KB)
----.gitattributes(19B)
----.github()
--------dependabot.yml(200B)
--------workflows()
----webpack.config.js(6KB)
----.prettierignore(0B)
----src()
--------.eslintrc(56B)
--------index.js(3KB)
----.babelrc(866B)
----webpack.config-test.web.js(899B)
----.npmignore(550B)
----GOVERNANCE.md(7KB)
----types()
--------tsconfig.json(266B)
--------test()
--------tslint.json(855B)
--------index.d.ts(284B)
----CONTRIBUTING.md(6KB)
----test()
--------mocha-bootstrap.js(131B)
--------.eslintrc(888B)
--------mocha-testem.mustache(543B)
--------mocha-multi.json(54B)
--------index.js(19KB)
----.prettierrc(440B)
----LICENSE.md(1KB)
----README.md(8KB)
----.husky()
--------commit-msg(56B)
--------pre-commit(53B)
--------.gitignore(1B)
----.lintstagedrc(94B)
----.commitlintrc.json(264B)
----SECURITY.md(2KB)
----.mocharc.js(215B)
----.npmrc(27B)
----testem.json(144B)
----.editorconfig(805B)
----CODE_OF_CONDUCT.md(3KB)
----.gitignore(144B)
----tonicExample.js(506B)
----tmp-test-bundle.js.LICENSE.txt(11KB)
----.eslintignore(81B)
----package-lock.json(544KB)
----package.json(4KB)
----.nycrc(227B)