@babel/preset-modules
0.2.0 · 17 Jun 2026MIT48.9M / weekRepositoryHomepagenpmAtom feed
Your version
0.2.0 is the newest release of 0.1.x.
Release note
@babel/preset-modules version 0.1.1 changes the behavior of JSX to fix compatibility with Edge 16-18. This preset originally compiled JSX Spread attributes to Object Spread expressions, however these are not supported in Edge. Instead, as of 0.1.1 JSX Spread is now transpiled to Object.assign() calls:
// input:
const X = <div a {...b} />
// previous output: (0.1.0):
const X = h('div', { a: true, ...b })
// new output: (0.1.1):
const X = h('div', Object.assign({ a: true }, b))The raw byte size has increased slightly, but this increase shrinks to near-0 when compressed using Gzip or Brotli, since the repeated Object.assign( calls are essentially free.