
Security News
Browserslist-rs Gets Major Refactor, Cutting Binary Size by Over 1MB
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
json-schema-view-js
Advanced tools
A pure JavaScript component for rendering JSON Schema in HTML.
JSON Schema is very verbose and hard to read in JSON. This component helps rendering a JSON Schema in a user readable format.
Also available as an AngularJS directive
Installation
Install via bower
bower install json-schema-view-js --save
Then use global JSONSchemaView
constructor
const schema = {type: 'string', title: 'Name'};
const view = new JSONSchemaView(schema);
document.body.appendChild(view.render());
JSONSchemaView(schema [, open ] [, options])
schema
(Object
) - requiredThe JSON Schema object.
open
(Number
)Default: 1
This number indicates up to how many levels the rendered tree should expand. Set it to 0
to make the whole tree collapsed or set it to Infinity
to expand the tree deeply
options
('Object')An object containing other options for construction the view. These are possible options:
theme
(string
)A theme defined in the CSS of this view. Possible values: dark
. Note that the dark theme is just for making the text brighter so it looks good on dark backgrounds.
Install gulp
and run gulp serve
to start the server that serves the development version of the project.
Once:
npm test
Continues:
gulp test
FAQs
JSON Schema View core library
The npm package json-schema-view-js receives a total of 220 weekly downloads. As such, json-schema-view-js popularity was classified as not popular.
We found that json-schema-view-js demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.
Security News
The official Go SDK for the Model Context Protocol is in development, with a stable, production-ready release expected by August 2025.