강의

멘토링

커뮤니티

Inflearn Community Q&A

duffufk12020319's profile image
duffufk12020319

asked

Easy to learn Webpack

[Practice] Getting started with Webpack

webpack app/index.js dist/bundle.js 시 오류가 뜹니다.

Written on

·

406

1

webpack app/index.js dist/bundle.js 시 오류가뜹니다.

계속 다시 해봐도 같은 증상이네요..4-

Built at: 2020-02-03 13:46:48
 1 asset
Entrypoint main = main.js
[1] multi ./app/index.js dist/bundle.js 40 bytes {0} [built]
[2] ./app/index.js 286 bytes {0} [built]
[3] (webpack)/buildin/global.js 472 bytes {0} [built]
[4] (webpack)/buildin/module.js 497 bytes {0} [built]
    + 1 hidden module

WARNING in configuration
The 'mode' option has not been set, webpack will fallback to 'production' for this value. Set 'mode' option 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/configuration/mode/

ERROR in multi ./app/index.js dist/bundle.js
Module not found: Error: Can't resolve 'dist/bundle.js' in 'C:\Users\tmdgn\Desktop\BOBA\webpack\LearnWebpack-master\LearnWebpack-master\getting-started'
 @ multi ./app/index.js dist/bundle.js main[1]
웹팩Bundling

Answer 2

1

Kyuwon Lee님의 프로필 이미지
Kyuwon Lee
Questioner

mode는 설정했는데 밑에 에러는 뭘까요?

0

captain님의 프로필 이미지
captain
Instructor

안녕하세요 규원님, 에러 로그를 보면 C:\Users\tmdgn\Desktop\BOBA\webpack\LearnWebpack-master\LearnWebpack-master\getting-started  위치에서 'dist/bundle.js' 를 해석할 수 없다고 나오네요. dist 폴더 밑의 bundle.js를 참조하는 코드를 한번 다시 살펴보시고. 만약 절대 경로로 되어 있다면 `./` 이런식으로 상대 경로 넣어주세요..!

duffufk12020319's profile image
duffufk12020319

asked

Ask a question