npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

ipos-printer

v1.2.1

Published

Capacitor plugin for Q2i PDA printer

Readme

ipos-printer

Plugin for Q2i PDA printer

Install

npm install ipos-printer
npx cap sync

API

getPrinterStatus()

getPrinterStatus() => Promise<{ result: number; }>

Get the printer status.

Returns: Promise<{ result: number; }>


getPrinterStatusMessage(...)

getPrinterStatusMessage(options: { status: number; }) => Promise<{ result: string; }>

Get the printer status message.

| Param | Type | Description | | ------------- | -------------------------------- | ------------------------------ | | options | { status: number; } | Object containing status value |

Returns: Promise<{ result: string; }>


setPrinterPrintDepth(...)

setPrinterPrintDepth(options: { depth: number; }) => Promise<{ result: string; }>

Sets the print font type, which has an effect on subsequent printing, unless initialized.

| Param | Type | Description | | ------------- | ------------------------------- | ----------------------------- | | options | { depth: number; } | Object containing depth value |

Returns: Promise<{ result: string; }>


setPrinterPrintFontType(...)

setPrinterPrintFontType(options: { typeface: string; }) => Promise<{ result: string; }>

Sets the print font type, which has an effect on subsequent printing, unless initialized. (Currently, only one font ST is supported, and more fonts will be supported in the future).

| Param | Type | Description | | ------------- | ---------------------------------- | -------------------------------- | | options | { typeface: string; } | Object containing typeface value |

Returns: Promise<{ result: string; }>


setPrinterPrintFontSize(...)

setPrinterPrintFontSize(options: { fontSize: number; }) => Promise<{ result: string; }>

Sets the print font size, which has an effect on subsequent printing, unless initialized. Currently, the font size is 16, 24, 32, and 48, and the default value of 24 is executed if the invalid size is entered

| Param | Type | Description | | ------------- | ---------------------------------- | -------------------------------- | | options | { fontSize: number; } | Object containing fontSize value |

Returns: Promise<{ result: string; }>


setPrinterPrintAlignment(...)

setPrinterPrintAlignment(options: { alignment: number; }) => Promise<{ result: string; }>

Sets the print alignment, which has an effect on subsequent printing, unless initialized.

| Param | Type | Description | | ------------- | ----------------------------------- | --------------------------------- | | options | { alignment: number; } | Object containing alignment value |

Returns: Promise<{ result: string; }>


printBlankLines(...)

printBlankLines(options: { lines: number; height: number; }) => Promise<{ result: string; }>

Printing blank lines (forced line wrapping, printing blank lines after the previous print, and all the data transferred to the printer is 0x00).

| Param | Type | Description | | ------------- | ----------------------------------------------- | ------------------------------------------- | | options | { lines: number; height: number; } | Object containing lines quantity and height |

Returns: Promise<{ result: string; }>


printText(...)

printText(options: { text: string; }) => Promise<{ result: string; }>

Print a text.

| Param | Type | Description | | ------------- | ------------------------------ | ---------------------------- | | options | { text: string; } | Object containing text value |

Returns: Promise<{ result: string; }>


printSpecifiedTypeText(...)

printSpecifiedTypeText(options: { text: string; typeface: string; fontSize: number; }) => Promise<{ result: string; }>

Print a text with specified type.

| Param | Type | Description | | ------------- | ------------------------------------------------------------------ | ---------------------------------------------------- | | options | { text: string; typeface: string; fontSize: number; } | Object containing text, typeface and fontSize values |

Returns: Promise<{ result: string; }>


PrintSpecFormatText(...)

PrintSpecFormatText(options: { text: string; typeface: string; fontSize: number; alignment: number; }) => Promise<{ result: string; }>

Print a text with specified format.

| Param | Type | Description | | ------------- | ------------------------------------------------------------------------------------- | --------------------------------------------------------------- | | options | { text: string; typeface: string; fontSize: number; alignment: number; } | Object containing text, typeface, fontSize and alignment values |

Returns: Promise<{ result: string; }>


printColumnsText(...)

printColumnsText(options: { colsTextArr: string[]; colsWidthArr: number[]; colsAlignArr: number[]; isContinuousPrint: number; }) => Promise<{ result: string; }>

Print a text with specified columns.

| Param | Type | Description | | ------------- | ------------------------------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------- | | options | { colsTextArr: string[]; colsWidthArr: number[]; colsAlignArr: number[]; isContinuousPrint: number; } | Object containing colsTextArr, colsWidthArr, colsAlignArr and isContinuousPrint values |

Returns: Promise<{ result: string; }>


printBitmap(...)

printBitmap(options: { alignment: number; bitmapSize: number; base64: string; }) => Promise<{ result: string; }>

Print a picture.

| Param | Type | Description | | ------------- | ----------------------------------------------------------------------- | --------------------------------------------------------- | | options | { alignment: number; bitmapSize: number; base64: string; } | Object containing alignment, bitmapSize and base64 values |

Returns: Promise<{ result: string; }>


printBarCode(...)

printBarCode(options: { data: string; symbology: number; height: number; width: number; textPosition: number; }) => Promise<{ result: string; }>

Print a barcode.

| Param | Type | Description | | ------------- | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------ | | options | { data: string; symbology: number; height: number; width: number; textPosition: number; } | Object containing data, symbology, height, width and textPosition values |

Returns: Promise<{ result: string; }>


printQRCode(...)

printQRCode(options: { data: string; moduleSize: number; errorCorrectionLevel: number; }) => Promise<{ result: string; }>

Print a QR code.

| Param | Type | Description | | ------------- | -------------------------------------------------------------------------------- | ------------------------------------------------------------------ | | options | { data: string; moduleSize: number; errorCorrectionLevel: number; } | Object containing data, moduleSize and errorCorrectionLevel values |

Returns: Promise<{ result: string; }>


printRawData(...)

printRawData(options: { data: string; }) => Promise<{ result: string; }>

Print the raw byte data.

| Param | Type | Description | | ------------- | ------------------------------ | ---------------------------- | | options | { data: string; } | Object containing data value |

Returns: Promise<{ result: string; }>


printRowBlock()

printRowBlock() => Promise<{ result: string; }>

Print a row block.

Returns: Promise<{ result: string; }>