Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 92d855e

Browse filesBrowse files
authored
docs(watchOnce): suggest to use Vue's native feature since 3.4 (#4743)
1 parent 38389f1 commit 92d855e
Copy full SHA for 92d855e

File tree

Expand file treeCollapse file tree

1 file changed

+6
-0
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+6
-0
lines changed

‎packages/shared/watchOnce/index.md

Copy file name to clipboardExpand all lines: packages/shared/watchOnce/index.md
+6Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@ category: Watch
66

77
`watch` that only triggers once.
88

9+
::: tip
10+
11+
[Once Watcher](https://vuejs.org/guide/essentials/watchers.html#once-watchers) has been added to Vue [since 3.4](https://github.com/vuejs/core/pull/9034), use `watch(watchSource, callback, { once: true })` instead on supported versions.
12+
13+
:::
14+
915
## Usage
1016

1117
After the callback function has been triggered once, the watch will be stopped automatically.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.