xsd-pattern-js
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

XSD-Pattern-JS

This library parse a XSD (XML Schema), as defined by w3c ,regular expression (as use in a pattern facet). It can output an equivalent javascript (ECMAScript) regexp. This allows to validate an XSD pattern directly in javascript.

This library is written in Typescript.

How to use it

Javascript

var xpj = require("xsd-pattern-js")
var pattern = new xpj.XsdPattern("A+");
pattern.match("AA"); //return true
pattern.match("AB"); //return false

Package Sidebar

Install

npm i xsd-pattern-js

Weekly Downloads

176

Version

1.0.0

License

Apache-2.0

Unpacked Size

141 kB

Total Files

30

Last publish

Collaborators

  • sboreux