DEV Community

Discussion on: Setting up Webpack 5 with React and Babel from scratch [2021]

Collapse
 
ashu78600 profile image
ashu78600

Nice tutorial . I think webpack will inject script tag in index.html. We don't need to do it manually. Instead of creating .babelrc we can inject it like this
use: {
loader: "babel-loader",
options: {
presets: ["@babel/preset-env", "@babel/preset-react"],
},
},