Skip to content

Instantly share code, notes, and snippets.

@ohcrfpv
Last active November 4, 2015 18:42
Show Gist options
  • Save ohcrfpv/8f83f43b2beccb5fa01f to your computer and use it in GitHub Desktop.
Save ohcrfpv/8f83f43b2beccb5fa01f to your computer and use it in GitHub Desktop.
javascript check int number
function isIntNumber(value) {
var numberRe = /^-?[0-9]+$/;
return typeof(value) === 'number' && numberRe.test(value);
}
@fdgogogo
Copy link

fdgogogo commented Nov 4, 2015

parseInt()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment