1. $ npm init -y
2. $ npm i -D parcel-bundler
// package.json
"scripts": {
"dev": "parcel index.html",
"build": "parcel build index.html"
},
index.html
js/main.js
scss/main.scss
reset.css
public/* // 이미지 파일 관련
$ npm install -D parcel-plugin-static-files-copy
$ npm i -D postcss autoprefixer
"browserslist": [
"> 1%", // 전세계 점유율 1% 이상의 모든 브라우저 지원
"last 2 versions" // 마지막 2개의 버전 지원
]
// 뒤에 rc(Runtime Configuration)
npm init -y
npm i parcel sass prettier -D
npm i navigo dotenv chartjs
// package.json
"scripts": {
"dev": "parcel index.html",
"build": "parcel build index.html"
},
"main": "index.js", -> "source": "index.html"