Array#from vs Spread array

Edit on GitHub

Setup

const arrOrig = Array(10000).fill(0);

Tests

  • Array#from

    const arr_1 = Array.from(arrOrig);
  • Spread array

    const [ ...arr_2 ] = arrOrig;