JavaScript Gotcha
If you are in the U.S. execute this JavaScript:
alert(new Date("2012-01-01").getFullYear());
Want to know why it returns 2011? Read my article
Written by JD Isaacks
Related protips
1 Response
Nice gotcha. I appreciate that you gave a little intro on the Coderwall post and not just a link to your blog. I am seeing that a fair amount lately.
over 1 year ago
·
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Javascript
Authors
Related Tags
#javascript
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#