New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

jsons2xsd

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jsons2xsd

Convert JSON Schemas to XSD

latest
npmnpm
Version
1.0.3
Version published
Weekly downloads
2
100%
Maintainers
1
Weekly downloads
 
Created
Source

jsons2xsd

JSON-Schema to XML schema converter written in JavaScript

Usage

After installation require / import the module and use it like this:

// import module
const XsdGenerator = require('jsons2xsd');

// do whatever needed to get your schema as either a string or a JSON object
const jsonSchema = getJsonSchema();

// create Generator instance 
const Generator = new XsdGenerator(jsonSchema);

// get a pretty formatted XSD based on the schema
const xsdString = Generator.convert().xmlString;

Not yet implemented

There is a bunch of features which are currently not implemented. Here is a list:

  • References ($ref property in JSON-Schema)
  • Arrays on root level
  • Different JSON-Schema Draft versions
  • Custom XSD Namespacing (namespace is set to http://www.w3.org/2001/XMLSchema)

FAQs

Package last updated on 01 Apr 2020

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