Correctly transform spreads to use proper concat method (#9108)

* Correctly transform spreads to use proper concat method

* Add tests to ensure array spread clones elements
This commit is contained in:
Daniel Tschinder
2018-12-13 23:24:43 -08:00
committed by GitHub
parent 72471aff63
commit 47da5cf75a
9 changed files with 62 additions and 5 deletions

View File

@@ -21,7 +21,7 @@ var _ref4 = [a[1], a[0]];
a[0] = _ref4[0];
a[1] = _ref4[1];
var _ref5 = babelHelpers.toConsumableArray(foo).concat([bar]),
var _ref5 = [].concat(babelHelpers.toConsumableArray(foo), [bar]),
a = _ref5[0],
b = _ref5[1];