GitBook: [zh_tw] 2 pages modified

This commit is contained in:
洪慈吟 2020-05-12 23:42:48 +00:00 committed by Justin Starry
parent ee543fee5b
commit 3266b892b1
2 changed files with 7 additions and 7 deletions

View File

@ -20,7 +20,7 @@
* [Elements](concepts/html/elements.md)
* [Literals & Expressions](concepts/html/literals-and-expressions.md)
* [Components](concepts/html/components.md)
* [Components](concepts/components/README.md)
* [元件](concepts/components/README.md)
* [Properties](concepts/components/properties.md)
* [Callbacks](concepts/components/callbacks.md)
* [Refs](concepts/components/refs.md)

View File

@ -1,20 +1,20 @@
---
description: Components and their lifecycle hooks
description: 元件,以及生命周期鉤子
---
# Components
# 元件
## What are Components?
## 什麼是元件?
Components are the building blocks of Yew. They manage their own state and can render themselves to the DOM. Components are created by implementing the `Component` trait which describes the lifecycle of a component.
元件是 Yew 的基石。他們管理自己的狀態,可以渲染自己成為 DOM。元件可以透過實作描述元件生命周期的 `Component` trait 來建立。
## Lifecycle
## 生命周期
{% hint style="info" %}
`Contribute to our docs:` [Add a diagram of the component lifecycle](https://github.com/yewstack/docs/issues/22)
{% endhint %}
## Lifecycle Methods
## 生命周期的方法
### Create