Open
Description
Vue version
3.5.13
Link to minimal reproduction
Steps to reproduce
- define a prop with any name(Ex:
value
) - input any code, to use the prop(Ex:
value
),console.log(value)
- before the prop use, input a function.It's param use prop's name(Ex:
value
),and function body insert an emptytry-catch
like demo. - will show error
value is not defined
.
What is expected?
Step 2 's code will compile into console.log(__props.value)
What is actually happening?
In @vue/compiler-sfc's code
and
when walk into function. And currentScope.value
is not revert to true
.cause this error!
In my opinion, this is a rather serious problem.
For example:
After the first use of props(value
), and before the second use of it, if there is a function whose parameter is the name of this prop(value
), then it will cause all subsequent properties to not function properly, leading to many issues.
System Info
Any additional comments?
No response