mediawiki-extensions-Popups/webpack.config.js
joakin fa2b10a2e7 Hygiene: Move build/ext.popups/ to src/
This way, src contains sources, and dist contains distribution files.

Also, add some documentation about the folders in the README and an adr.

Change-Id: Ie0b9f6475b8423b90e927633d883bde3cd5d5e4d
2017-02-14 09:59:59 -08:00

20 lines
528 B
JavaScript

var path = require( 'path' );
var webpack = require( 'webpack' );
var PUBLIC_PATH = '/w/extensions/Popups';
module.exports = {
output: {
// The absolute path to the output directory.
path: path.resolve( __dirname, 'resources/dist' ),
devtoolModuleFilenameTemplate: PUBLIC_PATH + '/[resource-path]',
// Write each chunk (entries, here) to a file named after the entry, e.g.
// the "index" entry gets written to index.js.
filename: '/[name].js'
},
entry: {
index: './src/index.js'
},
devtool: 'source-map'
};