inflearn logo
강의

강의

N
챌린지

챌린지

멘토링

멘토링

N
클립

클립

로드맵

로드맵

지식공유

쉽게 배우는 Webpack

[실습] Webpack 시작하기

web pack 에러

754

univue

작성한 질문수 15

1

Insufficient number of arguments or no entry found.

Alternatively, run 'webpack(-cli) --help' for usage info.

Hash: d6c939b5a5a99e62ccf4

Version: webpack 4.41.6

Time: 28ms

Built at: 02/29/2020 10:56:21 PM

WARNING in configuration

The 'mode' option has not been set, webpack will fallback to 'production' for this value. Set 'mode' optio

n to 'development' or 'production' to enable defaults for each environment.

You can also set it to 'none' to disable any default behavior. Learn more: https://webpack.js.org/configur

ation/mode/

ERROR in Entry module not found: Error: Can't resolve './src' in '/Users/yun-ali/Downloads/LearnWebpack-ma

ster'

웹팩 Bundling

답변 10

1

univue

1

univue

1

univue

{

  "name": "getting-started",

  "version": "1.0.0",

  "scripts": {

    "test": "echo \"Error: no test specified\" && exit 1",

    "build": "webpack"

  },

  "description": "",

  "main": "webpack.config.js",

  "keywords": [],

  "author": "",

  "license": "ISC"

}

1

univue

internal/modules/cjs/loader.js:250

    throw e;

    ^

SyntaxError: Error parsing /usr/local/lib/node_modules/webpack/package.json: Unexpected string in JSON at

position 8557

    at JSON.parse (<anonymous>)

    at readPackage (internal/modules/cjs/loader.js:239:25)

    at readPackageScope (internal/modules/cjs/loader.js:263:19)

    at Object.Module._extensions..js (internal/modules/cjs/loader.js:966:17)

    at Module.load (internal/modules/cjs/loader.js:811:32)

    at Function.Module._load (internal/modules/cjs/loader.js:723:14)

    at Function.Module.runMain (internal/modules/cjs/loader.js:1043:10)

    at internal/main/run_main_module.js:17:11 {

  path: '/usr/local/lib/node_modules/webpack/package.json'

}

npm ERR! code ELIFECYCLE

Git

GitHub

Create Repository

Initialize /Users/yun-ali/Downloads/LearnWebpack with a Git repository

Create repository

npm ERR! errno 1

npm ERR! getting-started@1.0.0 build: `webpack`

npm ERR! Exit status 1

npm ERR!

npm ERR! Failed at the getting-started@1.0.0 build script.

npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm WARN Local package.json exists, but node_modules missing, did you mean to install?

npm ERR! A complete log of this run can be found in:

npm ERR!     /Users/yun-ali/.npm/_logs/2020-03-01T10_32_35_467Z-debug.log

1

univue

npm ERR! missing script: build

npm ERR! A complete log of this run can be found in:

npm ERR!     /Users/yun-ali/.npm/_logs/2020-03-01T09_55_11_550Z-debug.log

1

univue

webpack 치면 에러가 자꾸 납니다.

0

캡틴판교

윤희님 혹시 다음에 진행하실 때 제가 원격으로 한번 봐드리면 좋을 것 같은데 진행하시기 전에 질문 한번 남겨주세요 ㅎㅎ

0

캡틴판교

오잉 윤희님, 위 json 파일 형식에는 딱히 에러 나는게 없네요..! 그런데도 npm run build 명령어가 안 먹나요?

0

캡틴판교

안녕하세요 윤희님, package.json 내용이 아래와 같이 잘 작성되었는지 한번 확인해보세요..! :)

{
  "name": "...",
  "version": "...",
  "scripts": {
     "build": "webpack"
  },
  ...
}

0

캡틴판교

윤희님 아래 문서의 6번 참고하셔서 package.json 파일에 "scripts" 관련된 코드 넣어주시고 `npm run build` 한번 돌려보세요 :)

https://joshua1988.github.io/webpack-guide/getting-started.html#%EC%8B%A4%EC%8A%B5-%EC%A0%88%EC%B0%A8-%EC%9B%B9%ED%8C%A9-%EB%B9%8C%EB%93%9C%EB%A5%BC-%EC%9C%84%ED%95%9C-%EA%B5%AC%EC%84%B1-%EB%B0%8F-%EB%B9%8C%EB%93%9C

강사님 리뉴얼 강좌 쿠폰 부탁드립니다.

2

367

4

안녕하세요. 리뉴얼 쿠폰 요청 드립니다.

1

230

1

안녕하세요!! 저도 부탁드립니다 ㅠㅠㅠ

1

279

1

안녕하세요. 리뉴얼 쿠폰 요청 드립니다.

1

299

2

리뉴얼 쿠폰 부탁드립니다 :)

1

256

2

리뉴얼 쿠폰 부탁드립니다!

1

213

1

리뉴얼 쿠폰 요청드립니다!

1

185

1

엇.. 저도 쿠폰 부탁드립니당

1

268

2

리뉴얼 쿠폰 요청드려도 될까요?

1

209

1

안녕하세요 저도 쿠폰 요청 드립니다 ㅠ__ㅠ

1

306

1

리뉴얼 쿠폰 발급 가능하신지요

1

259

1

리뉴얼 쿠폰 요청 드려도 될까요?

1

282

2

리뉴얼 쿠폰 받을 수 있을까요?

1

255

3

리뉴얼 쿠폰 요청 드려요! ㅠ.ㅠ

1

177

1

리뉴얼 쿠폰 요청드려도 될까요?

1

252

2

신규강좌 쿠폰 발급 가능할까요?ㅠㅠ

1

726

1

신규강좌 쿠폰 발급 가능해 주실 수 있을까요?

1

280

1

리뉴얼 강의 쿠폰 문의드려요.

1

262

2

쿠폰을 이제 봤는데 발급 가능할까요..?

1

351

3

리뉴얼 강의 쿠폰 발급 부탁드립니다.

1

244

1

리뉴얼 강의 쿠폰 문의

1

269

1

추가 강좌 개설해 주시면 어떨런지요? 시간이 되신다면요^^

1

155

1

쿠폰 주세요 ㅜㅜ

1

215

1

늦게 확인 했어요.. 쿠폰 가능할까요???? 감사합니다.

1

145

1