1.0.0 • Published 9 years ago

fluxslt v1.0.0

Weekly downloads
518
License
ISC
Repository
github
Last release
9 years ago

fluxslt

####Description

This library is a fluent wrapper with helper functions around xsltproc. It comes bundled with libxslt on your platform, so you'll need to make sure you've got that installed before you try running this.

####Example Usage

var stylesheet = fs.readFileSync('path/to/my/stylesheet', 'utf-8'),
    xmlContent = fs.readFileSync('path/to/xml/doc', 'utf-8'),
    fluxslt = require('fluent-xslt');

fluxslt()
    .withStylesheet(stylesheet)
    .runOn(xmlContent)
    .then(function(transformed) {
        console.log(transformed);
    });

###### or

var xmlContent = fs.readFileSync('path/to/xml/doc', 'utf-8'),
    fluxslt = require('fluent-xslt');

fluxslt()
    .withStylesheetPath('path/to/my/stylesheet')
    .runOn(xmlContent)
    .then(function(transformed) {
        console.log(transformed);
    });
1.0.0

9 years ago