Skip to content

Commit 353cd77

Browse files
authored
docs(cn): review and update
1 parent 442951f commit 353cd77

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/content/reference/react/use-client.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,7 @@ function App() {
200200
* 如果组件在带有 `'use client'` 指令的模块中定义,或者组件在客户端组件中导入并调用,那么组件的使用将是客户端组件。
201201
* 否则,组件的使用将是服务器组件。
202202

203+
203204
<Diagram name="use_client_render_tree" height={150} width={450} alt="一个树形图,其中每个节点代表一个组件及其子组件作为子组件。顶级节点标记为 'App',它有两个子组件 'InspirationGenerator' 和 'FancyText'。'InspirationGenerator' 有两个子组件,'FancyText' 和 'Copyright'。'InspirationGenerator' 和其子组件 'FancyText' 都标记为客户端渲染。">渲染树展示了组件的使用。</Diagram>
204205

205206
回到关于 `FancyText` 的问题,我们可以看到组件定义没有包含 `'use client'` 指令,并且它有两个使用方式。

0 commit comments

Comments
 (0)