#html-to-xlsx
node.js html to xlsx transformation
Transformation only supports html table and several basic style properties. No images or charts are currently supported.
var conversion = require("html-to-xlsx")();
conversion("<table><tr><td>cell value</td></tr></table>" }, function(err, stream){
stream.pipe(res);
});
##Supported properties
background-color
- cell background colorcolor
- cell foreground colorborder-left-style
- as well as positions will be transformed into excel cells borderstext-align
- text horizontal align in the excel cellvertical-align
- vertical align in the excel cellwidth
- the excel column will get the highest width, it can be little bit inaccurate because of pixel to excel points conversionheight
- the excel row will get the highest heightfont-size
- font size
##Options
var conversion = require("html-to-xlsx")({
numberOfWorkers: 2,
timeout: 5000,
tmpDir: "os/tmpdir",
portLeftBoundary: 1000,
portRightBoundary: 2000,
host: '127.0.0.1'
});
##License
See license