Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

isnumber

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

isnumber

A simple test to see if a value is a non-infinite number.

  • 1.0.0
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
124K
increased by12.8%
Maintainers
1
Weekly downloads
 
Created
Source

isNumber

NPM

isNumber is a super tiny module that provides a test to see if a value is a finite number.

By super tiny, I mean like a single line -- however, I tend to use this somewhat frequently, so module it is!

var isNumber = require("isnumber")

isNumber(13) // true
isNumber("1241.12") // true
isNumber(0xff) // true

isNumber(Infinity) // false
isNumber("cat") // false
isNumber({foo: "bar"}) // false

LICENSE

MIT

Keywords

FAQs

Package last updated on 14 Aug 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc