create-react-app 설치
$ npm install -g create-react-app
$ npm init react-app (Create fileName)
or
$ create-react-app .
or
$ npx create-react-app (Create fileName)
[ typescript ]
$ npm init react-app (Create fileName) --template typescript
or
$ create-react-app . --template typescript
or
$ npx create-react-app (Create fileName) --template typescript
create-react-app 실행
$ npm start
or
$ npm run start
create-react-app 빌드
$ npm build
or
$ npm run build
create-react-app 빌드 구동
$ npm install -g serve
$ serve -s build
or
$ npx serve -s build
⚠️ ※ npx 는 최신 버전의 패키지 실행 도구로, local에 저장되지 않고 한 번 실행하고 없어지는 방식이다.