A quick way to setup basic Webpack Encore
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
assets
.gitignore
LICENSE
README.md
index.html
package.json
webpack.config.js
yarn.lock

README.md

Kickstart

Since I use webpack encore for many of my projects and for the first steps I don’t need that much customizability, I use the same commands over and over again. With this repository, I want to just write down a quick step-by-step way to set up Webpack Encore.

Setup

  1. Copy assets (basic .js and .css files) folder to your root directory.

  2. Copy webpack.config.js (build settings) to your root directory.

  3. Follow these steps to install the npm packages:

yarn add @symfony/webpack-encore --dev
yarn add sass-loader node-sass --dev
yarn add webpack-notifier --dev

# If you want Bootstrap 4 incl. jQuery
yarn add bootstrap@4.0.0-beta.2 jquery popper.js --dev

# If you want Vue.js incl. hot module replacement
yarn add vue vue-loader vue-template-compiler --dev

Development

To develop ./node_modules/.bin/encore dev --watch

For production ./node_modules/.bin/encore production