Files
agent/webpack.config.js
Arpad Csanyi f34edcd7d1 Add publicPath to webpack config to fix dev-server's livereload.
The issue was that the webpack-dev-server seemed to serve the old files
instead of the newly bundled ones.
The explanation of the solution can be found here:
https://github.com/webpack/webpack-dev-server/issues/24#issuecomment-44366325
2016-08-01 21:37:03 +02:00

53 lines
1.3 KiB
JavaScript

// var webpack = require("webpack");
var SvgStore = require('webpack-svgstore-plugin');
module.exports = {
entry: ['es6-shim', 'zone.js', 'reflect-metadata', './src/boot.ts'],
output: {
path: __dirname + "/build",
publicPath: "/build/",
filename: "uhk.js"
},
devtool: 'source-map',
resolve: {
extensions: ['', '.webpack.js', '.web.js', '.ts', '.js'],
alias: {
},
modulesDirectories: [
'node_modules',
'bower_components'
]
},
module: {
loaders: [
{ test: /\.ts$/, loader: 'ts-loader', exclude: /node_modules/ },
{ test: /\.html$/, loader: 'html-loader' },
{
test: /\.scss$/,
exclude: /node_modules/,
loaders: ['raw-loader', 'sass-loader']
}
]
},
plugins: [
// new webpack.optimize.UglifyJsPlugin({ minimize: true })
new SvgStore(
[
'images/icons/**/*.svg'
],
'./',
{
name: 'compiled_sprite.svg',
chunk: 'app',
svgoOptions: {
plugins: [
{ removeTitle: true }
]
}
}
)
]
}