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

@cabletv102/evolve-badge-print

v1.0.1

Published

Used to print badges to Brother printers QL series.

Downloads

22

Readme

evolve-badge-print

Used to print badges to Brother printers QL series.

Install

npm install @cabletv102/evolve-badge-print
npx cap sync

API

searchBluetoothPrinters()

searchBluetoothPrinters() => Promise<{ printers: PrinterInfo[]; }>

Searches for Bluetooth printers using the Brother Mobile SDK for both android and ios.

Returns: Promise<{ printers: PrinterInfo[]; }>


ensureBluetoothEnabled()

ensureBluetoothEnabled() => Promise<{ enabled: boolean; }>

(Android only) Checks if Bluetooth is enabled, and if not, prompts the user to enable it in system settings.

Returns: Promise<{ enabled: boolean; }>


searchWifiPrinters(...)

searchWifiPrinters(options?: { timeout?: number | undefined; } | undefined) => Promise<{ printers: PrinterInfo[]; }>

Searches for Wifi printers using the Brother Mobile SDK for both android and ios.

| Param | Type | Description | | ------------- | ---------------------------------- | ---------------------------------------------------------------------- | | options | { timeout?: number; } | Optional parameters, e.g., timeout in seconds for the search duration. |

Returns: Promise<{ printers: PrinterInfo[]; }>


searchUSBPrinters(...)

searchUSBPrinters(options?: { timeout?: number | undefined; } | undefined) => Promise<{ printers: PrinterInfo[]; }>

Searches for USB printers using the Brother Mobile SDK FOR ANDROID ONLY.

| Param | Type | Description | | ------------- | ---------------------------------- | ---------------------------------------------------------------------- | | options | { timeout?: number; } | Optional parameters, e.g., timeout in seconds for the search duration. |

Returns: Promise<{ printers: PrinterInfo[]; }>


searchBLEPrinters(...)

searchBLEPrinters(options?: { timeout?: number | undefined; } | undefined) => Promise<{ printers: PrinterInfo[]; }>

Searches for BLE printers using the Brother Mobile SDK for both android and ios.

| Param | Type | Description | | ------------- | ---------------------------------- | ---------------------------------------------------------------------- | | options | { timeout?: number; } | Optional parameters, e.g., timeout in seconds for the search duration. |

Returns: Promise<{ printers: PrinterInfo[]; }>


transferTemplate(...)

transferTemplate(options: { templateName: string; templateData: string; printer: PrinterInfo; }) => Promise<{ success: boolean; }>

Transfers a template file to the printer.

| Param | Type | Description | | ------------- | ------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------ | | options | { templateName: string; templateData: string; printer: PrinterInfo; } | Object containing printer info and the template file data or path. |

Returns: Promise<{ success: boolean; }>


removeTemplateWithKey(...)

removeTemplateWithKey(options: { templateKey: Number; printer: PrinterInfo; }) => Promise<{ success: boolean; }>

Removes a template file currently available in the printer.

| Param | Type | Description | | ------------- | ------------------------------------------------------------------------------------------------------------ | ---------------------------------------------------- | | options | { templateKey: Number; printer: PrinterInfo; } | Object containing printer info and the template key. |

Returns: Promise<{ success: boolean; }>


getPrinterInfo(...)

getPrinterInfo(options: { printer: PrinterInfo; }) => Promise<{ details: Record<string, any>; }>

Gets detailed information about a connected printer.

| Param | Type | Description | | ------------- | ----------------------------------------------------------------- | ------------------------------------- | | options | { printer: PrinterInfo; } | Object containing the target printer. |

Returns: Promise<{ details: Record<string, any>; }>


printImage(...)

printImage(options: { imageBase64: string; printer: PrinterInfo; }) => Promise<{ success: boolean; }>

Prints a base64-encoded image to a printer.

| Param | Type | Description | | ------------- | -------------------------------------------------------------------------------------- | --------------------------------------------------------- | | options | { imageBase64: string; printer: PrinterInfo; } | Object containing the base64 image data and printer info. |

Returns: Promise<{ success: boolean; }>


printPDF(...)

printPDF(options: { pdfBase64: string; printer: PrinterInfo; }) => Promise<{ success: boolean; }>

Prints a PDF document to a printer.

| Param | Type | Description | | ------------- | ------------------------------------------------------------------------------------ | ------------------------------------------------------- | | options | { pdfBase64: string; printer: PrinterInfo; } | Object containing the base64 PDF data and printer info. |

Returns: Promise<{ success: boolean; }>


printImageFromURL(...)

printImageFromURL(options: { url: string; printer: PrinterInfo; }) => Promise<{ success: boolean; }>

Prints an image from a URL (or data URI) to a printer.

| Param | Type | Description | | ------------- | ------------------------------------------------------------------------------ | -------------------------------------------------- | | options | { url: string; printer: PrinterInfo; } | Object containing the URL string and printer info. |

Returns: Promise<{ success: boolean; }>


printTemplateWithKey(...)

printTemplateWithKey(options: { templateKey: string; replacers?: { [key: string]: any; } | undefined; printer: PrinterInfo; }) => Promise<{ success: boolean; }>

Prints a template to a printer using a specified template key and replacers.

| Param | Type | Description | | ------------- | --------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- | | options | { templateKey: string; replacers?: { [key: string]: any; }; printer: PrinterInfo; } | Object containing the template key, optional replacers, and printer info. |

Returns: Promise<{ success: boolean; }>


getTemplateInfo(...)

getTemplateInfo(options: { printer: PrinterInfo; }) => Promise<{ templateInfo: any[]; }>

Gets the template info from a printer.

| Param | Type | Description | | ------------- | ----------------------------------------------------------------- | ----------------------------------- | | options | { printer: PrinterInfo; } | Object containing the printer info. |

Returns: Promise<{ templateInfo: any[]; }>


Interfaces

PrinterInfo

| Prop | Type | Description | | ---------------- | ------------------- | --------------------------------------------- | | name | string | The name of the printer. | | model | string | The printer model, if available. | | macAddress | string | The MAC address of the printer, if available. | | ipAddress | string | The IP address of the printer, if applicable. |

Number

An object that represents a number of any kind. All JavaScript numbers are 64-bit floating-point numbers.

| Method | Signature | Description | | ----------------- | --------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- | | toString | (radix?: number | undefined) => string | Returns a string representation of an object. | | toFixed | (fractionDigits?: number | undefined) => string | Returns a string representing a number in fixed-point notation. | | toExponential | (fractionDigits?: number | undefined) => string | Returns a string containing a number represented in exponential notation. | | toPrecision | (precision?: number | undefined) => string | Returns a string containing a number represented either in exponential or fixed-point notation with a specified number of digits. | | valueOf | () => number | Returns the primitive value of the specified object. |

Type Aliases

Record

Construct a type with a set of properties K of type T

{ [P in K]: T; }