preact-hn icon indicating copy to clipboard operation
preact-hn copied to clipboard

Replace `Object.assign` polyfill

Open lukeed opened this issue 7 years ago • 0 comments

Instead of requiring a new file (object-assign-polyfill) which modifies the Object prototype, what if you used babel-plugin-transform-object-assign? It will rewrite Object.assign into _extends and inline a small helper function. It's fewer bytes for "fallback" and takes advantages of existing build tools.

Did you look into this approach before?

lukeed avatar Jul 26 '17 18:07 lukeed