Installation

npm

Install with npm:

$ npm install --save-dev webpkr

Configure Webpack

Create a webpack.config.js in your project’s root and add:

const webpkr = require('webpkr');
module.exports = webpkr({projectDir: __dirname});

Configure Webpkr

By default, webpkr looks for config scripts in a ./webpkr module. Create a webpkr subdirectory in your project’s root and add file index.js in it:

$ mkdir webpkr
$ touch webpkr/index.js

Add the following DSL script to webpkr/index.js:

context( projectDir )
entry( './src/index.js')
output( () => {
  filename( 'bundle.js' )
  path$( 'dist' )
} )