format-xml

0.0.0-work-in-progress • Public • Published

Travis – build statusCode climateDavid – status of dependenciesCode style: airbnb

format-xml

A streaming XML beautifier.
Fully customizable.
Opt-in – no magic.

Heads up: This is a work in progress. Ideas and criticism are very welcome.

Installation

  1. Make sure you have Node.js or io.js. On Unix-like systems you’re best off with nvm. Windows have official installers.

  2. Install the CLI for your user:

$ npm install --global format-xml

Usage

Out of the box – minimal output:

$ format-xml < dirty.xml > clean.xml

Smart presets:

$ format-xml --preset svg < dirty.svg > clean.svg

CLI configuration:

$ format-xml --indent-string "\t" < dirty.xml > clean.xml

JSON or safe CSON configuration:

echo "indentString: '\t'" > .format-xml.cson
$ format-xml < dirty.xml > clean.xml
# or: 
$ format-xml --config-file .format-xml.cson < dirty.xml > clean.xml

License

MIT © Tomek Wiszniewski

Package Sidebar

Install

npm i format-xml

Weekly Downloads

1

Version

0.0.0-work-in-progress

License

MIT

Last publish

Collaborators

  • tomekwi