Webpack is a module bundler. Its main purpose is to bundle JavaScript files for usage in a browser, but it is also capable of transforming, bundling, or packaging just about any resource or asset. It is made primarily for JavaScript, but it can transform front-end assets such as HTML, CSS, and images if the corresponding loaders are included.

Webpack start

  1. Download the latest theme source from the Bootstrap Marketplace.
  2. Download and install Node.js from Nodejs. The suggested version to install is 14.16.x LTS or up to the latest available version.
  3. Unpack/extract the downloaded theme
  4. Start a command prompt window or terminal and change directory to [unpacked path]/dashly/theme/.
    cd dashly/theme/
  5. Install the latest NPM:
    npm install -g npm@latest
  6. Install the dependencies:
    npm install
  7. Run the build task to build the theme. The command below will compile all the assets (Sass, JavaScript, media) to the dashly/theme/dist/assets/ folder and the HTML/Handlebars files to the dashly/theme/dist/ folder.
    npm run build
    or open a local dev server to make changes on the theme. This command starts the localhost server and the webpack real-time watcher. This task watches the Sass, JavaScript and HTML/Handlebars files and automatically recompiles whenever the source files are changed.
    npm run start