node-odt
OpenDocument Text(.odt) generator working with templates and data (like Mustache)
Install
$ npm install node-odt
Usage
In the template:
Prenom: {prenom},Nom: {nom}
Code:
const fs = ;const path = ; const odtTemplate = ;const uuid = ; const file = fs; const odtHandle = file;const data = nom: "Docy" prenom: "Daniel"; //type: "nodebuffer", "base64", "stream"odtHandle ;
Output odt file:
Prenom: Daniel,Nom: Docy