Skip to content
This repository has been archived by the owner on Nov 16, 2022. It is now read-only.

Update workshop code to use webpack 5 on backend #206

Closed
trivikr opened this issue Oct 1, 2020 · 1 comment · Fixed by #217
Closed

Update workshop code to use webpack 5 on backend #206

trivikr opened this issue Oct 1, 2020 · 1 comment · Fixed by #217

Comments

@trivikr
Copy link
Contributor

trivikr commented Oct 1, 2020

Is your feature request related to a problem? Please describe.
Webpack 5 release is planned on 2020-10-10 webpack/webpack#11406

Describe the solution you'd like
The backend code in workshop repo uses webpack 5
Currently it uses webpack 4

"webpack": "4.44.1",
"webpack-cli": "3.3.11"

Describe alternatives you've considered
Continue using webpack 4 as it's not going to be deprecated anytime soon.

Additional context
Webpack 5 fixes the bug with tree shaking in multiple entry points webpack/webpack#4453
Existing hack to avoid that bug

const entry = glob.sync("./src/*.ts").reduce((acc, item) => {
const name = item.replace("./src/", "").replace(".ts", "");
acc[name] = item;
return acc;
}, {});

@trivikr
Copy link
Contributor Author

trivikr commented Oct 1, 2020

webpack 5 support will drop in create-react-app (frontend) mostly in v4.1.x
facebook/create-react-app#9510 (comment)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant