44 lines
633 B
JavaScript
44 lines
633 B
JavaScript
|
|
var webpack = require ('webpack');
|
|
var path = require ('path');
|
|
|
|
module.exports =
|
|
{
|
|
entry: {
|
|
'salix.core': ['@salix/core'],
|
|
'salix.app': ['@salix/app']
|
|
},
|
|
output: {
|
|
path: path.join (__dirname, 'build'),
|
|
filename: '[name].js',
|
|
publicPath: 'build/'
|
|
},
|
|
module: {
|
|
loaders: [
|
|
{
|
|
test: /\.js$/,
|
|
loader: 'babel',
|
|
exclude: /node_modules/,
|
|
query: {
|
|
presets: ['es2015']
|
|
}
|
|
},{
|
|
test: /\.html$/,
|
|
loader: 'raw'
|
|
}
|
|
]
|
|
},
|
|
resolve: {
|
|
modulesDirectories: [
|
|
__dirname,
|
|
'node_modules'
|
|
]
|
|
},
|
|
plugins: [
|
|
new webpack.optimize.CommonsChunkPlugin ({
|
|
name: 'salix.core'
|
|
})
|
|
]
|
|
};
|
|
|