title: How to create date occurrence between two dates by giving days gap?
body: <p>I have the below data:</p>
  
  <p>1 year contract</p>
  
  <pre><code>Start Date: 01-01-2019
  
  End Date: 31-12-2019
  </code></pre>
  
  <p>15 days gap between start and end date exclude all Fridays</p>
  
  <p><strong>Exact Expected output exclude all Fridays</strong></p>
  
  <pre><code>19-01-2019 //exclude Fridays then got 19 jan 2019
  -----------
  05-02-2019 //after 15 days
  -----------
  23-02-2019 //after 15 days
  -------------
  keep on adding.. hit until end month 12-2019
  </code></pre>
  
  <p>How to generate it?Is there a better approach for doing this?</p>
  
  <pre><code>var start = new Date("2019-01-01");
  var end = new Date("2019-12-31");
  
  while (start &lt;= end) {
      console.log( new Date(start) );
      start.setMonth( start.getMonth() + 1 );
  }
  </code></pre>