plexis-js / plexis

Lo-fi, powerful, community-driven string manipulation library.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Feature request: `isDigit`

vorillaz opened this issue · comments

Checks whether the input text contains only digit characters.

Example usage

import isDigit from '@plexis/is-digit';

isDigit('1');
// => true

isDigit('2');
// => true

isEmpty('0xFF');
// => true

isEmpty('5e-2');
// => true

isDigit('0.5e2');
// => true

isEmpty('   ');
// => false

isEmpty('A');
// => false

isEmpty(',.');
// => false

isEmpty('Hello world!');
// => false

isEmpty('Ελληνικά');
// => false

Aliases

import isDigit from '@plexis/is-digit';
import {isDigit} from 'plexis';

Can I work on this one?

@hugonxc Sure, just create a PR and you are ready to go! Thanks for the effort.

@hugonxc Snap, this is of a duplicate of #9 . Can you pick another one?

Ok! I'll look for it!