@types/power-radix
TypeScript icon, indicating that this package has built-in type declarations

2.5.2 • Public • Published

Installation

npm install --save @types/power-radix

Summary

This package contains type definitions for power-radix (https://github.com/cflynn07/power-radix).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/power-radix.

index.d.ts

/**
 * Convert number from source radix to target radix
 * with optional custom character encoding
 * http://www.deimel.org/comp_sci/conversion.htm
 */
declare class PowerRadix {
    /**
     * Creates a new instance of PowerRadix
     */
    constructor(digits: string | number | number[], sourceRadix: number | number[]);

    /**
     * Convert to target radix, return as Array
     * @param targetRadix - target radix / encoding characters
     * @return  source digits converted to target radix presented in format of Array
     */
    toArray(targetRadix: number | string[]): string[];

    /**
     * Convert to target radix, return as String
     *
     * @param targetRadix - target radix / encoding characters
     * @return - source digits converted to target radix presented in format of Array
     */
    toString(targetRadix: number | string[]): string;
}

export = PowerRadix;

Additional Details

  • Last updated: Tue, 07 Nov 2023 09:09:39 GMT
  • Dependencies: none

Credits

These definitions were written by Piotr Błażejewicz.

Readme

Keywords

none

Package Sidebar

Install

npm i @types/power-radix

Weekly Downloads

51

Version

2.5.2

License

MIT

Unpacked Size

4.37 kB

Total Files

5

Last publish

Collaborators

  • types