You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a function is defined with multiple arguments and the first one is not being used, then once the function is called with arguments passed via object spread operator (fn(...[arg1, arg2])), rollup build (with treeshake: true) should preserve all the arguments.
Actual Behavior
If a function fn(arg1, arg2) {...} is using only arg2 and not arg1, then when it is called using the spread operator fn(...[arg1, arg2]), the rollup build removes all the arguments. It works fine, if you call it without the spread operator fn(arg1, arg2) or disable rollups treeshake configuration.
The text was updated successfully, but these errors were encountered:
Expected Behavior
When a function is defined with multiple arguments and the first one is not being used, then once the function is called with arguments passed via object spread operator (
fn(...[arg1, arg2])
), rollup build (withtreeshake: true
) should preserve all the arguments.Actual Behavior
If a function
fn(arg1, arg2) {...}
is using onlyarg2
and notarg1
, then when it is called using the spread operatorfn(...[arg1, arg2])
, the rollup build removes all the arguments. It works fine, if you call it without the spread operatorfn(arg1, arg2)
or disable rollupstreeshake
configuration.The text was updated successfully, but these errors were encountered: