Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

compare two dates using moment

moment('2010-10-20').isAfter('2010-01-01', 'year'); // false
moment('2010-10-20').isAfter('2009-12-31', 'year'); // true
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #compare #dates #moment
ADD COMMENT
Topic
Name
3+6 =