Modern JS development
What is Modern JS development
簡単的に言うと、ES5以後のSyntaxを利用する
Why we need Modern JS?
1. fast web application,
2. fast development, https://github.com/vitejs/vite
3. Try to get rid of node_modules
考え方面
Code
map, filter, =>, async/await など
Tools
Vite
Snowpack
今日は Tools 周りを話す、メインは Vite
Vite は何ですか?
Next generation frontend tooling. It's fast!
簡単的に言うと、
native ES modules を活用して、webpack ような dev/bundle ツールです。
Compare Vite and vue-cli(Webpack)
Why Vite fast
webpack は source code を全部読み込んで処理する後、Server ready
https://gyazo.com/497a11eb004f689c5926a45fe31e3404
vite は Server ready 後、ESM で source code を読む
https://gyazo.com/98878ebc6ebd67bd22d2c4191f8a4877
onuma.icon ES Modulesがそのままimportできるようになったのは大きいですよね!
ブラウザで覚えるES Modules入門 - JavaScriptでモジュールを使う時代 - ICS MEDIA
Other Tools
https://github.com/preactjs/wmr
What I think about it?
確かに fast
しかし SSR framework はまだ対応しない
積極的に検証して、勇気を持って small project に使う
#勉強会
#Vite
#Vuejs
refs
https://docs.google.com/presentation/d/1X1hrFw18v67bEniTPpaI_DBulLdkKNFEc_3nVEm95mM/edit#slide=id.ga7017d88ae_0_72
https://web.dev/publish-modern-javascript/
created by TJ