@jsreport/jsreport-html-to-xlsx
Advanced tools
Comparing version 3.0.1 to 3.1.0
@@ -18,2 +18,3 @@ const fs = require('fs').promises | ||
let htmlToXlsxHelpers | ||
reporter.initializeListeners.add('html-to-xlsx', async () => { | ||
@@ -23,2 +24,8 @@ htmlToXlsxHelpers = (await fs.readFile(path.join(__dirname, '../static/helpers.js'))).toString() | ||
reporter.registerHelpersListeners.add('htmlToXlsx', (req) => { | ||
if (req.template.recipe === 'html-to-xlsx') { | ||
return htmlToXlsxHelpers | ||
} | ||
}) | ||
reporter.beforeRenderListeners.insert({ after: 'data' }, 'htmlToXlsx', async (req) => { | ||
@@ -32,5 +39,3 @@ if (req.template.recipe !== 'html-to-xlsx') { | ||
req.data.$writeToFiles = ['cheerio', 'chrome'].includes((req.template.htmlToXlsx || {}).htmlEngine) | ||
req.context.systemHelpers += htmlToXlsxHelpers + '\n' | ||
}) | ||
} |
{ | ||
"name": "@jsreport/jsreport-html-to-xlsx", | ||
"version": "3.0.1", | ||
"version": "3.1.0", | ||
"description": "jsreport recipe capable of converting html into excel", | ||
@@ -37,5 +37,5 @@ "keywords": [ | ||
"dependencies": { | ||
"@jsreport/office": "3.0.0", | ||
"chrome-page-eval": "1.3.0", | ||
"html-to-xlsx": "2.2.0", | ||
"@jsreport/office": "3.0.0", | ||
"nanoid": "1.0.7", | ||
@@ -47,10 +47,10 @@ "node.extend.without.arrays": "1.1.6", | ||
"devDependencies": { | ||
"handlebars": "4.7.7", | ||
"@jsreport/jsreport-core": "3.1.0", | ||
"@jsreport/jsreport-core": "3.2.0", | ||
"@jsreport/jsreport-handlebars": "3.0.0", | ||
"@jsreport/studio-dev": "3.0.1", | ||
"handlebars": "4.7.7", | ||
"mocha": "5.2.0", | ||
"puppeteer": "10.4.0", | ||
"should": "13.2.3", | ||
"standard": "16.0.3", | ||
"standard": "16.0.4", | ||
"xlsx-populate": "1.20.1" | ||
@@ -57,0 +57,0 @@ }, |
877372
1058