How to find the day of month in momentjs -


how can find day of month current moment date points to. on here iam trying invoke dayofmonth()

 var compareday = function(ts1,ts2){            return (moment(ts1).dayofmonth() === moment(ts2).dayofmonth())?true:false;  }; 

per documentation,

moment#date date of month, , moment#day day of week.

so believe want,

return moment(ts1).date() === moment(ts2).date(); 

Comments

Popular posts from this blog

google api - Incomplete response from Gmail API threads.list -

Installing Android SQLite Asset Helper -

Qt Creator - Searching files with Locator including folder -