์ฐธ๊ณ : [Node.js ์ฝ๋๋ฉ] 1.์ค๋ฆฌ์ํ ์ด์ | ๊น์ ํ ๋ธ๋ก๊ทธ (jeonghwan-kim.github.io)
ํ๋ก ํธ์๋ ๊ฐ๋ฐํ๊ฒฝ์ ์ดํด: NPM | ๊น์ ํ ๋ธ๋ก๊ทธ (jeonghwan-kim.github.io)
1. ๊ฐ๋ฐ์ ์งํํ ์ ๋นํ ๋นํด๋ ํ๋ ๋ง๋ค๊ธฐ
์๋ ์์๋๋ก ์์ฑํ๊ธฐ
npm init
ํ๋ก์ ํธ ์์ฑ ๋ช ๋ น์ด๋ก, ํ๋ก์ ํธ์ ๋ฉํ ์ ๋ณด๋ฅผ ์ ๋ ฅํ ์ ์๋ ํ๋ฉด์ด ์ ๊ณต๋๋ค.
์๋์ ๊ฐ์ด ๋ฌ๋ค
npm init
This utility will walk you through creating a package.json file.
It only covers the most common items, and tries to guess sensible defaults.
See `npm help init` for definitive documentation on these fields
and exactly what they do.
Use `npm install <pkg>` afterwards to install a package and
save it as a dependency in the package.json file.
Press ^C at any time to quit.
package name: (feunderstanding)
ํจํค์ง ๋ค์์ ๋ณดํต ํ๋ก์ ํธ ๋ค์์ด๋ฏ๋ก ํด๋๋ช ์ ์๋ง๊ฒ ์์ฑํ๋ค๋ฉด ์ํฐ
๊ณ์ ์ํฐ
Press ^C at any time to quit.
package name: (feunderstanding)
version: (1.0.0)
description:
entry point: (index.js)
test command:
git repository:
keywords:
author:
license: (ISC)
About to write to ๊ฒฝ๋ก๊ฒฝ๋ก๊ฒฝ๋ก๊ฒฝ๋ก\package.json:
{
"name": "feunderstanding", // ํ๋ก์ ํธ ์ด๋ฆ
"version": "1.0.0", //๋ฒ์
"description": "", //์ค๋ช
"main": "index.js",
"scripts": { //ํ๋ก์ ํธ๋ฅผ ์๋ํํ ์ ์๋ ์์คํฌ๋ฆฝํธ๋ฅผ ์
๋ ฅํ ์ ์๋ ๋ถ๋ถ
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "", //ํ๋ก์ ํธ ์์ฑ์
"license": "ISC" //๋ผ์ด์ผ์ค ์ ๋ณด
}
Is this OK? (yes)
์ํฐ
ls
๋๋ ํฐ๋ฆฌ: C:๊ฒฝ๋ก\FEUnderstanding
Mode LastWriteTime Length Name
---- ------------- ------ ----
-a---- 2022-03-26 ์ค์ 10:26 211 package.json
์์๊ฐ์ด ๋ด์ผ๋ฉด ๋ ๊ฒ!
'Javascript > FE ๊ฐ๋ฐํ๊ฒฝ์ค์ ' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
[์นํฉ][๋ฐ๋ฒจ] ํจํค์ง ์ด ์ค์น (0) | 2022.05.10 |
---|---|
[FE ๋ฒ๋ค๋ฌ] parceljs (0) | 2022.05.07 |