✅ Migration completed: - server.js: Complete rewrite using docxtemplater + pizzip - server-old.js: Backup of original docx-templates implementation - package.json: Added docxtemplater and pizzip dependencies - Removed docx-templates dependency 🚀 New features: - True dynamic tables with {#array}{field}{/array} syntax - Unlimited table rows (no more fixed array indices) - New API endpoints: /analyze, /generate, /demo - Simplified template creation scripts 🎯 Template improvements: - Updated template syntax examples - Added dynamic-template.docx with loop syntax - Enhanced template analysis functionality 📊 Benefits: - Real dynamic table generation - Better template flexibility - Cleaner API design - Preserved SSL and WebDAV functionality
27 lines
615 B
JSON
27 lines
615 B
JSON
{
|
|
"name": "docx-template-server",
|
|
"version": "1.0.0",
|
|
"description": "Node.js server for filling DOCX templates with data",
|
|
"main": "server.js",
|
|
"scripts": {
|
|
"start": "node server.js",
|
|
"dev": "nodemon server.js"
|
|
},
|
|
"dependencies": {
|
|
"adm-zip": "^0.5.16",
|
|
"basic-auth": "^2.0.1",
|
|
"cors": "^2.8.5",
|
|
"docx": "^9.5.1",
|
|
"docx-templates": "^4.10.2",
|
|
"docxtemplater": "^3.66.4",
|
|
"express": "^4.18.2",
|
|
"jszip-utils": "^0.1.0",
|
|
"multer": "^1.4.5-lts.1",
|
|
"pizzip": "^3.2.0",
|
|
"webdav-server": "^2.6.2"
|
|
},
|
|
"devDependencies": {
|
|
"nodemon": "^3.0.1"
|
|
}
|
|
}
|