defineComponent
is no longer tree-shakeable without /* @__PURE__ */
with rollup since 3.0.0-rc.3
#8236
Labels
🔨 p3-minor-bug
Priority 3: this fixes a bug, but is an edge case that only affects very specific usage.
Vue version
3.3.0-beta.4
Link to minimal reproduction
Rollup REPL
Steps to reproduce
defineComponent
code.defineComponent
function inutils.js
.What is expected?
The
defineComponent
function is detected as side-effect free by Rollup as described in the document.What is actually happening?
The
defineComponent
function is not detected as side-effect free by Rollup.It seems the
extend
call and the property access (options.name
) is treated as side-effectful.related commits: 304830a, d77557c
System Info
No response
Any additional comments?
Original issue: vitejs/vite#13087
The text was updated successfully, but these errors were encountered: