Skip to content

Commit 64f9be3

Browse files
authored
Fix typo, track function name should be 'track' instead of 'effect' (#925)
1 parent 3281700 commit 64f9be3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/guide/reactivity.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ console.log(proxy.meal)
157157
Remember this list from a few paragraphs ago? Now we have some answers to how Vue handles these changes:
158158

159159
- <strike>Detect when there’s a change in one of the values</strike>: we no longer have to do this, as Proxies allow us to intercept it
160-
- **Track the function that changes it**: We do this in a getter within the proxy, called `effect`
160+
- **Track the function that changes it**: We do this in a getter within the proxy, called `track`
161161
- **Trigger the function so it can update the final value**: We do in a setter within the proxy, called `trigger`
162162

163163
The proxied object is invisible to the user, but under the hood they enable Vue to perform dependency-tracking and change-notification when properties are accessed or modified. As of Vue 3, our reactivity is now available in a [separate package](https://github.com/vuejs/vue-next/tree/master/packages/reactivity). One caveat is that browser consoles format differently when converted data objects are logged, so you may want to install [vue-devtools](https://github.com/vuejs/vue-devtools) for a more inspection-friendly interface.

0 commit comments

Comments
 (0)