Closed simonihmig closed 1 year ago
Hey @wessberg, any chance you could have a look at this?
Hi all 👋
PR https://github.com/wessberg/rollup-plugin-ts/pull/205 has been created 3 month ago to fix this, but no activity on this ticket or the PR since…
Is there a chance this could get a review?
Hi there,
As rollup-plugin-ts
is no longer implicitly adding any syntax-/proposal babel plugins such as object-rest-spread
since v3.3.0, I'm closing this issue. Thanks.
tsc
(if applicable): n/aReproduction
Expected Behavior
I am trying to apply only the explicitly configured babel plugins, and otherwise let the code be "ESLatest".
The docs say:
According to this, I am expecting only the explicitly configured babel plugins to be used. Which means the object spread is not transpiled away.
Actual Behavior
My use of object spread syntax is unnecessarily transpiled away, and this babel helper function is included as a polyfill into the bundle.
Comment
Amongst others,
@babel/plugin-proposal-object-rest-spread
is added implicitly here. I do not understand the rationale behind this logic. Why are these plugins implicitly added? And why specifically these five? Object spread is AFAIK an approved ES2018 feature, supported in all modern browsers and node. So no need for transpilation by default, and without a way to disable this behavior.