node-xslt-java-bridge
TypeScript icon, indicating that this package has built-in type declarations

1.0.2 • Public • Published

node-xslt-java-bridge

Node.js module exposes basic XSLT API through Java bridge to The Saxon XSLT and XQuery Processor from Saxonica Limited.

Includes Saxon-HE distribution. All notices can be found in bridge/vendor/SaxonHE9-7-0-14J/notices/ directory.

License: MPL 2.0

Installation

npm install node-xslt-java-bridge -S

Usage

var Transformer = require('node-xslt-java-bridge').Transformer;
 
var transformer = new Transformer('template.xsl');
var results = transformer.transform({
    base: '/absolute/path/to/working/dir',
    path: 'path/to/document.xml',
    contents: '<xml>...</xml>'
});
console.log(results[0].contents);

Also see examples/ in the source repository.

Troubleshooting: Popup dialog to install legacy JAVA SE 6 on macOS

It could be because the Oracle JDK does not advertise itself as available for JNI. Please see this issue for more details and manual workarounds.

API

Please refer to index.d.ts file.

Gulp Plugin

There is also a plugin for Gulp based on this module — gulp-xslt2.

Readme

Keywords

Package Sidebar

Install

npm i node-xslt-java-bridge

Weekly Downloads

16

Version

1.0.2

License

MPL-2.0

Last publish

Collaborators

  • nocheinabeiter