We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b2be75b commit c2172f3Copy full SHA for c2172f3
packages/runtime-core/src/apiDefineComponent.ts
@@ -279,6 +279,9 @@ export function defineComponent(
279
extraOptions?: ComponentOptions
280
) {
281
return isFunction(options)
282
- ? extend({ name: options.name }, extraOptions, { setup: options })
+ ? // #8326: extend call and options.name access are considered side-effects
283
+ // by Rollup, so we have to wrap it in a pure-annotated IIFE.
284
+ /*#__PURE__*/ (() =>
285
+ extend({ name: options.name }, extraOptions, { setup: options }))()
286
: options
287
}
0 commit comments