Javascript/FE ๊ฐœ๋ฐœํ™˜๊ฒฝ์„ค์ •

node.js ์ด์šฉํ•ด์„œ ํ”„๋ก ํŠธ์—”๋“œ ๊ฐœ๋ฐœ ํ”„๋กœ์ ํŠธ ์ƒ์„ฑํ•˜๊ธฐ

Rainbow๐ŸŒˆCoder 2022. 3. 26. 10:39
728x90

์ฐธ๊ณ : [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

์œ„์™€๊ฐ™์ด ๋–ด์œผ๋ฉด ๋œ ๊ฒƒ!

 

728x90