node-printer icon indicating copy to clipboard operation
node-printer copied to clipboard

Print HTML content

Open NikunjChotaliya opened this issue 7 years ago • 5 comments

I have to generate print based on that some html content, for that i have write one function which gives me html

within that html code arise, and now how can i print this html ?

Is there any way to do that ?

My code is here :: var printer = require('printer')

printer.printDirect({ data: some HTML content like header etc.., printer: 'Epson-TM-BA-Thermal', type: 'RAW', // may i provide any other type of html? success: function (jobID) { console.log('sent to printer with ID: ' + jobID) }, error: function (err) { console.log(err) } })

NikunjChotaliya avatar Dec 05 '17 12:12 NikunjChotaliya

+1

ajaiy avatar Jan 09 '18 09:01 ajaiy

+1

rishabh-webdev avatar May 19 '18 13:05 rishabh-webdev

Convert to PDF first maybe.

ghost avatar Jul 30 '18 00:07 ghost

+1

shaniqwa avatar Aug 22 '18 13:08 shaniqwa

+1

cesarmejiag avatar Jan 15 '19 05:01 cesarmejiag