1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

【Vue.js】プロパティとライフサイクルフックの早見表

Last updated at Posted at 2021-04-15

Vue プロパティ

プロパティ名 役割
el VueインスタンスをどのHTML要素に結び付けるを定義
data Vueインスタンスが保持するデータ(状態)を定義する
methods Vueインスタンスのメソッド(振る舞い)を定義する
filters Vueインスタンスが持つフィルターを定義する
computed Vueインスタンスが持つ算出プロパティを定義する
watch Vueインスタンスが持つウォッチャを定義する
components Vueインスタンスが持つコンポーネントを定義する
props コンポーネントが持つプロパティを定義する
emits コンポーネントが発行するイベントを定義する

Vue ライフサイクルフック

フック名 発生のタイミング
beforeCreate Vueインスタンスが生成された直後に発生
created リアクティブデータを監視する準備が終わった時
beforeMount VueインスタンスがDOMと結びつく直前
mounted VueインスタンスがDOMと結びついた直後
beforeUpdate リアクティブデータが更新され、DOMに反映される直前
updated リアクティブデータが更新され、DOMに反映された直後
beforeUnmount Vueインスタンスのマウントが解除される直前
unmounted Vueインスタンスのマウントが解除された直後
beforeDestroy Vueインスタンスが破棄される直前
destroyed Vueインスタンスが破棄された直後
1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?