Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR TYPESCRIPT

display moment in format dd/mm/yy only last two digits of year

var formatL = moment.localeData().longDateFormat('L');
var formatYearlessL = formatL.replace(/YYYY/g,'YY');
console.log(moment().format(formatYearlessL));
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #display #moment #format #digits #year
ADD COMMENT
Topic
Name
9+7 =