npm

Need private packages and team management tools?Check out npm Orgs. »

@jsmicro/is-number

1.0.2 • Public • Published

JSMicro - Is Number

isNumber(object)

Check does the given Javascript Object (array, object, string, etc) is a number.

isNotNumber(object)

Check does the given Javascript Number (array, object, string, etc) is not a number.

Browser Usage

bower install --save jsmicro-is-number
<script type="text/javascript" src="bower_components/jsmicro-is-number/index.js">
<script type="text/javascript">
    var obj = 200;
    var nbr = 'String';
 
    // Available in the window object.
    isNumber(obj);      // true
    isNumber(nbr);      // false
    isNotNumber(nbr);   // true
</script> 

NodeJS Usage

npm install --save @jsmicro/is-number
const obj = require('@jsmicro/is-number');
 
// Available in the global object.
isNumber(2344342432); // true
isNumber('23322333'); // false
isNotNumber('23234'); // true
 
// Also available in the export object.
obj.isNumber(2343244432); // true
obj.isNumber('23322333'); // false
obj.isNotNumber('23333'); // true

Changelogs

v1.0.1 - May 21, 2016

  • Added .npmignore

v1.0.0 - May 19, 2016

  • Initial release.

The MIT License (MIT)

install

npm i @jsmicro/is-number

Downloadsweekly downloads

4

version

1.0.2

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability