fast-isnumeric

WebJar for fast-isnumeric

Лицензия

Лицензия

MIT
Группа

Группа

org.webjars.npm
Идентификатор

Идентификатор

fast-isnumeric
Последняя версия

Последняя версия

1.1.4
Дата

Дата

Тип

Тип

jar
Описание

Описание

fast-isnumeric
WebJar for fast-isnumeric
Ссылка на сайт

Ссылка на сайт

https://www.webjars.org
Система контроля версий

Система контроля версий

https://github.com/plotly/fast-isnumeric

Скачать fast-isnumeric

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/org.webjars.npm/fast-isnumeric/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>fast-isnumeric</artifactId>
    <version>1.1.4</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/fast-isnumeric/
implementation 'org.webjars.npm:fast-isnumeric:1.1.4'
// https://jarcasting.com/artifacts/org.webjars.npm/fast-isnumeric/
implementation ("org.webjars.npm:fast-isnumeric:1.1.4")
'org.webjars.npm:fast-isnumeric:jar:1.1.4'
<dependency org="org.webjars.npm" name="fast-isnumeric" rev="1.1.4">
  <artifact name="fast-isnumeric" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='fast-isnumeric', version='1.1.4')
)
libraryDependencies += "org.webjars.npm" % "fast-isnumeric" % "1.1.4"
[org.webjars.npm/fast-isnumeric "1.1.4"]

Зависимости

compile (1)

Идентификатор библиотеки Тип Версия
org.webjars.npm : is-string-blank jar [1.0.1,2)

Модули Проекта

Данный проект не имеет модулей.

fast-isnumeric

The fast way to check if a JS object is numeric

Install

npm install fast-isnumeric

API

var isNumeric = require('fast-isnumeric');

isNumeric(/* any JS object */);

How fast

Run comparison on jsperf: http://jsperf.com/isnumeric-jquery-and-alternate/5

Warning

Please look up the test cases in test.js before using this module.

Most importantly, fast-isnumeric returns false on number and string constructors. That is, isNumeric(new Number(1)) and isNumeric(new String('1')) are false.

Tests

Test locally with karma:

npm test

Why?

In plotly's javascript graphing library plotly.js numerical objects must be accounted for in numerous hot code paths. Inspired by Jon Schlinkert's is-number, fast-isnumeric is significantly simplified and sped up by ignoring number and string constructors.

Author

Alex Johnson | https://github.com/alexcjohnson

License

Copyright (c) 2015 Alex Johnson Released under the MIT license.

org.webjars.npm

Plotly

Версии библиотеки

Версия
1.1.4
1.1.3
1.1.2
1.1.1