@jsep-plugin/numbers
TypeScript icon, indicating that this package has built-in type declarations

1.0.1 • Public • Published

npm size

@jsep-plugin/numbers

A JSEP plugin for adding support for additional number formats, hexadecimal, binary and octal. It also adds support to ignore _ characters in numbers

jsep('0xA'); // hexadecimal (10)  
jsep('0b01001010'); // binary (74)
jsep('0644'); // octal (420)
jsep('0o644'); // octal (420)
jsep('115_200'); // decimal (115200)

Install

npm install @jsep-plugin/numbers
# or
yarn add @jsep-plugin/numbers

Usage

import jsep from 'jsep';
import jsepNumbers from '@jsep-plugin/numbers';
jsep.plugins.register(jsepNumbers);

Meta

LICENSE (MIT)

Readme

Keywords

none

Package Sidebar

Install

npm i @jsep-plugin/numbers

Weekly Downloads

810

Version

1.0.1

License

MIT

Unpacked Size

64.8 kB

Total Files

15

Last publish

Collaborators

  • 6utt3rfly
  • leaverou
  • smekkie
  • soney