Closed
Description
var c = { ...a, x: 1 }
transpiles to
var c = Object.assign({}, a, { x: 1 })
It works all nice and dandy but it implicitly requires a polyfill that is undocumented. I assume this is because of the recent change to move the polyfill into a module? Perhaps react (react-tools) should not use the jstransform spread visitor, using one that leverages React.__spread
as in the jsx case? Or at perhaps just a note in the docs somewhere that you will need Object.assign
polyfilled.
Metadata
Metadata
Assignees
Labels
No labels