Skip to content

Commit 4e5cd47

Browse files
sdrasnaokie
authored andcommitted
update lifecycle diagram and optimize it (#767)
1 parent ec69fed commit 4e5cd47

File tree

3 files changed

+154
-3
lines changed

3 files changed

+154
-3
lines changed
-399 KB
Binary file not shown.
Lines changed: 147 additions & 0 deletions
Loading

src/guide/instance.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@
55
全ての Vue アプリケーションは `createApp` 関数で新しい **アプリケーションインスタンス (application instance)** を作成するところから始まります:
66

77
```js
8-
const app = Vue.createApp({ /* options */ })
8+
const app = Vue.createApp({
9+
/* options */
10+
})
911
```
1012

1113
The application instance is used to register 'globals' that can then be used by components within that application. We'll discuss that in detail later in the guide but as a quick example:
@@ -35,7 +37,9 @@ The options passed to `createApp` are used to configure the **root component**.
3537
An application needs to be mounted into a DOM element. For example, if we want to mount a Vue application into `<div id="app"></div>`, we should pass `#app`:
3638

3739
```js
38-
const RootComponent = { /* options */ }
40+
const RootComponent = {
41+
/* options */
42+
}
3943
const app = Vue.createApp(RootComponent)
4044
const vm = app.mount('#app')
4145
```
@@ -109,4 +113,4 @@ Vue.createApp({
109113

110114
以下はインスタンスライフサイクルのダイアグラムです。これは今完全に理解する必要はありませんが、さらに学習し実践すれば、便利なリファレンスとなることでしょう。
111115

112-
<img src="/images/lifecycle.png" width="840" height="auto" style="margin: 0px auto; display: block; max-width: 100%;" loading="lazy" alt="Instance lifecycle hooks">
116+
<img src="/images/lifecycle.svg" width="840" height="auto" style="margin: 0px auto; display: block; max-width: 100%;" loading="lazy" alt="Instance lifecycle hooks">

0 commit comments

Comments
 (0)