티스토리 뷰

1. cmd(터미널)에서 프로젝트 폴더로 이동

 

2. 프로젝트 폴더를 npm package로 지정(package.json 생성)

npm init

// 명령어 입력 후 환경설정
// name
// version
// description
// entry point
// test command
// git respository
// keywords
// author
// license
// Is this ok? (yes)

 

 

- 예제로 UnderscoreJS 설치

 

3. UnderscoreJS 홈페이지에서 설치법 확인

 

4. cmd(터미널)에 설치 명령어 입력(node_modules 폴더가 생성되고 하위에 underscore 폴더가 생성됨)

npm install underscore --save

* '--save' 를 추가하면 package.json의 dependencies 항목에 추가됨.

(새로운 프로젝트에서 package.json을 이용해서 라이브러리들을 설치할 수 있음)

'Framework > Express.js' 카테고리의 다른 글

Nodejs 동기/비동기  (0) 2021.02.10
Underscore.js  (0) 2021.02.10
npm으로 UglifyJS 설치 및 사용  (0) 2021.02.10
Express.js 시작  (0) 2021.02.09
Node.js 시작  (0) 2021.02.09
댓글
Total
Today
Yesterday
링크
Apple 2023 맥북 프로 14 M3, 스페이스 그레이, M3 8코어, 10코어 GPU, 512GB, 8GB, 한글