Basic Webpack use example with JavaScript files.
Source code for Using Webpack 4 to transform and package web application resources blog post. Versión en Español: Usar Webpack 4 para transformar y empaquetar recursos de una aplicación web
- Clone.
npm install
npm run build
node ./dist/main.js
./dist/main.js
contains the webpack bundle based on ./index.js
file and dependencies.