Next.js Discord

Discord Forum

Build failed because of webpack errors

Answered
American Chinchilla posted this in #help-forum
Open in Discord
American ChinchillaOP
Failed to compile.

../../node_modules/buffer/index.js
Module parse failed: Unexpected token (509:18)
File was processed with these loaders:
 * ./node_modules/next/dist/build/webpack/loaders/next-flight-client-module-loader.js
 * ./node_modules/next/dist/build/webpack/loaders/next-swc-loader.js
You may need an additional loader to handle the result of these loaders.
|   }
| 
>   // Force coercio

Import trace for requested module:
../../node_modules/buffer/index.js
./node_modules/axios/lib/helpers/toFormData.js
./node_modules/axios/lib/axios.js
./node_modules/axios/index.js
./src/app/(app)/(login)/page.tsx


> Build failed because of webpack errors

did someone face such error? cause i have no idea what may be causing it
Answered by American Chinchilla
actually i somehow solved it by installing latest version of buffer instead of depending on what version dependencies install
View full answer

2 Replies

maybe be moe of this page could help
./src/app/(app)/(login)/page.tsx
American ChinchillaOP
actually i somehow solved it by installing latest version of buffer instead of depending on what version dependencies install
Answer