Skip to content

Commit ec3a66e

Browse files
committed
docs(): fix docs about how to close drawer during unmount for increment rendering
1 parent e1adbc0 commit ec3a66e

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

docs/advanced/incremental-rendering.mdx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,14 @@ routes:
7777
method: open
7878
onUnmount:
7979
target: '#detail-drawer'
80-
method: close
80+
properties:
81+
visible: false
82+
# 以上示例针对 v3 构件,对于 v2 的 drawer/modal 构件,没有 `visible` 属性,
83+
# 需使用 `close` 方法并设置 `noEvent: true`:
84+
# target: '#v2-drawer'
85+
# method: close
86+
# args:
87+
# - noEvent: true
8188
# highlight-end
8289
events:
8390
# 当抽屉关闭时,回到列表页

i18n/zh/docusaurus-plugin-content-docs/current/advanced/incremental-rendering.mdx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,14 @@ routes:
7777
method: open
7878
onUnmount:
7979
target: '#detail-drawer'
80-
method: close
80+
properties:
81+
visible: false
82+
# 以上示例针对 v3 构件,对于 v2 的 drawer/modal 构件,没有 `visible` 属性,
83+
# 需使用 `close` 方法并设置 `noEvent: true`:
84+
# target: '#v2-drawer'
85+
# method: close
86+
# args:
87+
# - noEvent: true
8188
# highlight-end
8289
events:
8390
# 当抽屉关闭时,回到列表页

0 commit comments

Comments
 (0)