-
-
Notifications
You must be signed in to change notification settings - Fork 9k
Closed as not planned
Closed as not planned
Copy link
Description
Vue version
^3.5.17
Link to minimal reproduction
Steps to reproduce
A component passes in an object, part of which is a reactive value (defined by shallowRef or ref ), watch the props in the component, and every time the page element is updated, the watcher in the component is triggered
const opt = ref({}) <Comp :option="{
someBaseOpt: '',
newConfig: opt
}" />watch(
() => props.option,
(val, old) => {
console.log('watch?????????', val, old);
alert('triggered the watcher')
}
);I think this may be a bug
What is expected?
Only triggered when props actually change
What is actually happening?
Unrelated page element changes will trigger
System Info
Any additional comments?
No response
Metadata
Metadata
Assignees
Labels
No labels