0
0

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 5 years have passed since last update.

Udemyで学んだVue.jsの仮想DOMの話

Posted at

VNode(仮想node)

  • DOM要素ではない
  • DOM要素を模したJavaScriptオブジェクト
  • DOMに直接アクセスするのはスピードが遅い
  • どうすれば効率よくあまりいじらずに済むか

アルゴリズム的な話で

  • 仮想DOMはDOMのドキュメントオブジェクトの形になってる
  • 本物のDOMはJavaScriptでなくHTMK上にある
  • そこにアクセスするのに時間がかかる
  • JavaScript上ならすぐアクセスして変更できたりする
  • 前回作った仮想DOMと、今新しく作った仮想DOMを見比べて、変わってる分だけ実際のDOMに適用する(mount)
スクリーンショット 2020-02-20 15.18.15.png
0
0
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
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?