fast-xml-parser alternatives and similar modules
Based on the "Parsing" category.
Alternatively, view fast-xml-parser alternatives based on common mentions on social networks and blogs.
-
markdown-it
Markdown parser, done right. 100% CommonMark support, extensions, syntax plugins & high speed -
remark
remark is a popular tool that transforms markdown with plugins. These plugins can inspect and change your markup. You can use remark on the server, the client, CLIs, deno, etc. -
nearley
๐๐๐ฒ Simple, fast, powerful parser toolkit for JavaScript. -
@parcel/css
An extremely fast CSS parser, transformer, bundler, and minifier written in Rust. -
parse5
HTML parsing/serialization toolset for Node.js. WHATWG HTML Living Standard (aka HTML5)-compliant. -
csv-parser
Streaming csv parser inspired by binary-csv that aims to be faster than everyone else -
google-libphonenumber
The up-to-date and reliable Google's libphonenumber package for node.js. -
xlsx-populate
Excel XLSX parser/generator written in JavaScript with Node.js and browser support, jQuery/d3-style method chaining, encryption, and a focus on keeping existing workbook features and styles in tact. -
json-mask
Tiny language and engine for selecting specific parts of a JS object, hiding the rest. -
strip-json-comments
Strip comments from JSON. Lets you use comments in your JSON files! -
Awesome phonenumber parser
Google's libphonenumber pre-compiled with the closure compiler -
json-query
Retrieves values from JSON objects for data binding -
safe-json-value
โ๏ธ JSON serialization should never fail -
binary-extract
Extract a value from a buffer of json without parsing the whole thing -
parsec ๐
๐ Tiniest body parser in the universe. Built for modern Node.js -
docx-to-pdf-on-AWS-Lambda
Microsoft Word doc/docx to PDF conversion on AWS Lambda using Node.js
Appwrite - The Open Source Firebase alternative introduces iOS support
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of fast-xml-parser or a related project?
README
fast-xml-parser
Validate XML, Parse XML to JS Object, or Build XML from JS Object without C/C++ based libraries and no callback.
Looking for maintainers
Check ThankYouBackers for our contributors
Users
Check the list of all known users [here](./USERs.md);
The list of users is collected either from the list published by Github, cummunicated directly through mails/chat , or from other resources. If you feel that your name in the above list is incorrectly published or you're not the user of this library anymore then you can inform us to remove it. We'll do the necessary changes ASAP.
Main Features
- Validate XML data syntactically
- Parse XML to JS Object
- Build XML from JS Object
- Works with node packages, in browser, and in CLI (press try me button above for demo)
- Faster than any other pure JS implementation.
- It can handle big files (tested up to 100mb).
- Controlled parsing using various options
- XML Entities, HTML entities, and DOCTYPE entites are supported.
- unpaired tags (Eg
<br>
in HTML), stop nodes (Eg<script>
in HTML) are supported. - You can restore almost same XML from JSON
- Supports comments
- It can preserve Order of tags in JS object
- You can control if a single tag should be parsed into array.
- Supports parsing of PI (Processing Instruction) tags with XML declaration tags
- And many more other features.
How to use
To use as package dependency
$ npm install fast-xml-parser
or
$ yarn add fast-xml-parser
To use as system command
$ npm install fast-xml-parser -g
To use it on a webpage include it from a CDN
Example
As CLI command
$ fxparser some.xml
In a node js project
const { XMLParser, XMLBuilder, XMLValidator} = require("../src/fxp");
const parser = new XMLParser();
let jObj = parser.parse(XMLdata);
const builder = new XMLBuilder();
const xmlContent = builder.build(jObj);
In a HTML page
<script src="path/to/fxp.min.js"></script>
:
<script>
const parser = new fxparser.XMLParser();
parser.parse(xmlContent);
</script>
Check lib folder for different browser bundles
Bundle Name | Size |
---|---|
fxbuilder.min.js | 5.2K |
fxparser.js | 50K |
fxparser.min.js | 17K |
fxp.min.js | 22K |
fxvalidator.min.js | 5.7K |
Documents
v3
- [documents](./docs/v3/docs.md)
v4
- [GettingStarted.md](./docs/v4/1.GettingStarted.md)
- [XML Parser](./docs/v4/2.XMLparseOptions.md)
- [XML Builder](./docs/v4/3.XMLBuilder.md)
- [XML Validator](./docs/v4/4.XMLValidator.md)
- [Entities](./docs/v4/5.Entities.md)
- [HTML Document Parsing](./docs/v4/6.HTMLParsing.md)
- [PI Tag processing](./docs/v4/7.PITags.md) ## Performance
XML Parser
[](./docs/imgs/XMLParser_v4.png)
Large files [](./docs/imgs/XMLParser_large_v4.png)
XML Builder
[](./docs/imgs/XMLBuilder_v4.png)
negative means error
Our other projects and research you must try
- BigBit standard :
- Single text encoding to replace UTF-8, UTF-16, UTF-32 and more with less memory.
- Single Numeric datatype alternative of integer, float, double, long, decimal and more without precision loss.
- Cytorus: Be specific and flexible while running E2E tests.
- Run tests only for a particular User Story
- Run tests for a route or from a route
- Customizable reporting
- Central dashboard for better monitoring
- Options to integrate E2E tests with Jira, Github etc using Central dashboard
Tian
.
- Stubmatic : Create fake webservices, DynamoDB or S3 servers, Manage fake/mock stub data, Or fake any HTTP(s) call.
Supporters
Contributors
This project exists thanks to [all](graphs/contributors) the people who contribute. [[Contribute](docs/CONTRIBUTING.md)]. <!-- --> <!--
Lead Maintainers
All Contributors -->
Backers
Thank you to all our backers! ๐ [Become a backer]
Sponsors
[Become a sponsor] Support this project by becoming a sponsor. Your logo will show up here with a link to your website. Please also share your detail so we can thankyou on SocialMedia.
License
- MIT License
[Donate $5](static/img/donation_quote.png)
*Note that all licence references and agreements mentioned in the fast-xml-parser README section above
are relevant to that project's source code only.