Cordial greeting colleagues, is that I'm using momentjs for handling dates in my application, my problem is that I need to compare a start date and an end date, then fill an array with the dates you are among these, eg if I have a start date and an end date 2018/09/07 2018/09/10 then the values of my array should be the following: array = [ '2018/09/08', '2018/09/09'], probe using the diff function I found in the documentation:
var moment = require('moment');
let init_date = moment(self.crono.init_date);
let end_date = moment(self.crono.end_date);
console.log(end_date.diff(init_date, 'days'), ' dias de diferencia');
but in doing this I get the days of difference, but I do not get the dates as such that I need.
How could I fill the array with the dates I need?