npm

pos-print
TypeScript icon, indicating that this package has built-in type declarations

1.0.5 • Public • Published

pos-print

esc tsc print for nodejs
This module dependencies node-printer

How to use

  • javascript const print = require('pos-print');
  • typescript import * as print from 'pos-print'

API

  • getPrinters()
    Get all installed printers

  • printText(printerName:string, text:string)
    Return Promise
    Print text,print.printText('epson-58','hello!')

  • printRaw(printerName:string, data:any)
    Return Promise
    Print cmd,print.printRaw('epson-58','\x1b\x40')

  • printImageByTSC(options)
    options{ printer: string; url: string; pageWidth: number; pageHeight: number; gap: number; copy: number; }
    Return Promise
    Print image by TSC

  • printImageByESC(options)
    options{ printer: string; url: string; maxWidth: number; }
    Return Promise
    Print image by ESC/POS

Readme

Keywords

Package Sidebar

Install

npm i pos-print

Weekly Downloads

0

Version

1.0.5

License

ISC

Unpacked Size

6.56 kB

Total Files

4

Last publish

Collaborators

  • keyiis