Skip to content

Instantly share code, notes, and snippets.

View j1mmie's full-sized avatar

Jimmie Tyrrell j1mmie

View GitHub Profile
@j1mmie
j1mmie / gist:bd674a9f2cd843fe297e
Last active August 29, 2015 14:23
Javascript int parsing cheatsheet
value parseInt(value) +value value|0
0 0 0 0
10 10 10 10
10.9 10 10.9 10
-1 -1 -1 -1
-1.9 -1 -1.9 -1
'10' 10 10 10
'ten' NaN NaN 0
null 0 NaN 0