earthkingman / 42Swim

42서울 QnA 서비스
14 stars 3 forks source link

웹팩에서 vite로 초기세팅 변경 #64

Closed Yenowme closed 2 years ago

Yenowme commented 2 years ago

vite 설정

checkList

주의사항

nyeoni commented 2 years ago

Vite 공식 페이지 https://vitejs.dev/

Yenowme commented 2 years ago

허광남 멘토님 설명 페이지 https://okdevtv.com/mib/vite

nyeoni commented 2 years ago

Vite 란?

Vite 의 문제인식 및 장점

Javascript modules 시스템을 사용하기 위해 Webpack, Rollup, Parcel 과 같은 다양한 번들러들이 나타났다. 그러나 이러한 번들러들을 사용할때 큰 프로젝트일 수록 트랜스파일의 시간이 많이 들고 dev server 새로고침 등과 같은 비효율성을 낳았었다. Vite 는 Webpack 을 기반으로 하지 않으며 브라우저에서 네이티브 ES 모듈을 활용하는 자체 개발 서버를 가지고 있다. 또한 웹팩의 개발 서버보다 훨씬 더 빠른 속도를 제공하고 빌드를 위해 Rollup 을 사용하여 빠른 속도를 더해준다.

PS)

Webpack 과 Vite 의 비교

Webpack 의 Bundle based dev server

image

Vite 의 Natvie ESM based dev server

image

kenu commented 2 years ago

이거 좀 재밌어요. JavaScript 번들러로 본 조선시대 붕당의 이해 image

image from: https://wormwlrm.github.io/2020/08/12/History-of-JavaScript-Modules-and-Bundlers.html

Yenowme commented 2 years ago

의문점

kenu commented 2 years ago

Let's google it! https://www.google.com/search?q=babel+vite

nyeoni commented 2 years ago

Vite - ESbuild https://vitejs.dev/guide/features.html#jsx https://esbuild.github.io/content-types/#jsx

Yenowme commented 2 years ago

78 done