moment js add string code example
Example 1: moment js print date
moment(testDate).format('MM/DD/YYYY');
Example 2: moment format heure
var time = "15:30:00";
var formatted = moment(time, "HH:mm:ss").format("LT");
console.log(formatted);
//it will return 3:30 PM
Example 3: moment get day
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');