How to find the day, month and year with moment.js

The Solution to How to find the day, month and year with moment.js is


Just try with:

var check = moment(n.entry.date_entered, 'YYYY/MM/DD');

var month = check.format('M');
var day   = check.format('D');
var year  = check.format('YYYY');

JSFiddle

~ Answered on 2014-07-28 13:43:39


Most Viewed Questions: