Open whitetrefoil opened 2 years ago
Thanks for the debugging tip! decorator is too complex to be used :(
Anyway the workaround works. Since Vue 3 has been release for long, I guess only aged projects use this now, targeting ES2021 should be totally enough. 😹
I just got this error during upgrading of legacy project.
Post here just In case 😹 anyone else meets this problem during upgrading.
Workaround
Set
"target"
of TypeScript to"ES2021"
or lower.Analysis
TS changes the transpiled JS code of class properties when targeting ES2022 or higher (not sure started from what version of TS, just tested the latest v4.8.4).
Since
collectData
incore.ts
also usesdefineProperty
, this change causes redefine property errors.