title: How to seperate object data into each sheet of CSV file for Javascript
body: <p>I need your help or advice to loop my data below figure1 to CSV file which can be separated by DeviceA and DeviceB in sheet of excel file.</p>
  
  <p>Let's see example file details that the data will be separated by sheet ProductDay1 and ProductDay2 via <a href="http://jsfiddle.net/qxLn3h86/48/" rel="nofollow noreferrer">http://jsfiddle.net/qxLn3h86/48/</a></p>
  
  <p><b> Figure1 </b></p>
  
  <pre><code>var dataObj = 
  { deviceA:
     [ [ 'DeviceA' ],
       [ 'Date/Time', 'smokeSensor', 'fireSensor' ],
       [ '01/05/19 0001', '200', '700' ],
       [ '01/05/19 0002', '300', '750' ],
       [ '02/05/19 0001', '20', '780' ],
       [ '02/05/19 0002', '30', '630' ]],
    deviceB:
     [ [ 'DeviceB' ],
       [ 'Date/Time', 'smokeSensor', 'fireSensor' ],
       [ '01/06/19 0001', '100', '600' ],
       [ '01/06/19 0002', '110', '522' ],
       [ '02/06/19 0001', '120' ],
       [ '02/06/19 0002', '130' ] ] 
  }
  </code></pre>