]> git.ipfire.org Git - thirdparty/vuejs/router.git/commitdiff
docs: update chinese api document (#957)
authorLee <peteralfredlee@gmail.com>
Wed, 26 May 2021 07:49:52 +0000 (15:49 +0800)
committerGitHub <noreply@github.com>
Wed, 26 May 2021 07:49:52 +0000 (09:49 +0200)
docs/zh/api/index.md

index 91b33084c399024abcb1d383af4f9aa210b8ca25..d65ebd14f37d96203ca591132739f63c5d46dfb3 100644 (file)
@@ -520,7 +520,7 @@ _参数_
 #### 示例
 
 ```js
-router.beforeEach(to => {
+router.beforeResolve(to => {
   if (to.meta.requiresAuth && !isAuthenticated) return false
 })
 ```
@@ -746,12 +746,12 @@ routes: RouteRecordRaw[]
 
 ### scrollBehavior
 
-在页面之间导航时控制滚动的函数。可以返回一个 Promise 来延迟滚动。
+在页面之间导航时控制滚动的函数。可以返回一个 Promise 来延迟滚动。有关更多详细信息,请参见[滚动行为](../guide/advanced/scroll-behavior.md)。
 
 **函数签名:**
 
 ```typescript
-scrollBehavior?: ScrollBehavior
+scrollBehavior?: RouterScrollBehavior
 ```
 
 #### 示例