node-easy-docx
Version:
NodeJs library to parse docx file content into JSON format.
42 lines (31 loc) • 1.07 kB
Markdown
NodeJs library to parse docx file content into JSON format.
**node-easy-docx** provides a simple solution to parse Office Open XML format files, ONLY **docx**, into JSON Object.
> Please read [Office Open XML](http://officeopenxml.com/anatomyofOOXML.php) for more information.
node-easy-docx exposes .docx file into well structured and organized JSON objects. Using JavaScript, you can easily render HTML or any other document.
Currently node-easy-docx supports paragraphs and text formats only. Other features like - Images, Tables, Absolute contents are still in development.
``` bash
npm install --save node-easy-docx
```
``` js
const EasyDocx = require('node-easy-docx')
const easyDocx = new EasyDocx({
path: 'path/to/docx/file'
})
easyDocx.parseDocx()
.then(data => {
// JSON data as result
console.log(data)
})
.catch(err => {
console.error(err)
})
```
[](https://opensource.org/licenses/MIT)
[](https://github.com/saikksub)