Socket
Socket
Sign inDemoInstall

@kie-tools/xml-parser-ts

Package Overview
Dependencies
0
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @kie-tools/xml-parser-ts

This lets you parse/build XML strings from/to JSON using types and metadata generated with `@kie-tools/xml-parser-ts-codegen`. It uses DOMParser or `jsdom` to parse the XMLs and guarantees that:


Version published
Maintainers
1
Install size
65.4 kB
Created

Readme

Source

@kie-tools/xml-parser-ts

This lets you parse/build XML strings from/to JSON using types and metadata generated with @kie-tools/xml-parser-ts-codegen. It uses DOMParser or jsdom to parse the XMLs and guarantees that:

  1. Parse/builds are idempotent for XMLs created with
  2. The JSON resulting from parsing is type-safe, as the metada generated by @kie-tools/xml-parser-ts-codegen provides information on what is a string, a boolean, an integer, a float or an array. Even if there's only one element on a sequence, @kie-tools/xml-parser-ts will make sure it is an array with length 1.
  3. The types generated by @kie-tools/xml-parser-ts-codegen can be extended and parsed/built.
  4. Unknown elements/attributes are kept in the original JSON.
  5. Comments ignored.

Some characteristics:

  1. Namespaces declared on the original XML can be preserved when building from the JSON.

FAQs

Last updated on 11 Oct 2023

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc