Skip to content

Commit

Permalink
fix: add missing anchors on watchers and render-function (#2677)
Browse files Browse the repository at this point in the history
  • Loading branch information
edimitchel committed Jan 22, 2024
1 parent 076aa55 commit a4c52b9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/guide/essentials/watchers.md
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ Similar to component updates, user-created watcher callbacks are batched to avoi

By default, a watcher's callback is called **after** parent component updates (if any), and **before** the owner component's DOM updates. This means if you attempt to access the owner component's own DOM inside a watcher callback, the DOM will be in a pre-update state.

### Post Watchers
### Post Watchers {#post-watchers}

If you want to access the owner component's DOM in a watcher callback **after** Vue has updated it, you need to specify the `flush: 'post'` option:

Expand Down Expand Up @@ -379,7 +379,7 @@ watchPostEffect(() => {

</div>

### Sync Watchers
### Sync Watchers {#sync-watchers}

It's also possible to create a watcher that fires synchronously, before any Vue-managed updates:

Expand Down
2 changes: 1 addition & 1 deletion src/guide/extras/render-function.md
Original file line number Diff line number Diff line change
Expand Up @@ -577,7 +577,7 @@ JSX equivalent:

Passing slots as functions allows them to be invoked lazily by the child component. This leads to the slot's dependencies being tracked by the child instead of the parent, which results in more accurate and efficient updates.

### Scoped Slots
### Scoped Slots {#scoped-slots}

To render a scoped slot in the parent component, a slot is passed to the child. Notice how the slot now has a parameter `text`. The slot will be called in the child component and the data from the child component will be passed up to the parent component.

Expand Down

0 comments on commit a4c52b9

Please sign in to comment.