electrojet-scripts
Version:
Build scripts for use with create-electrojet
37 lines (34 loc) • 655 B
JavaScript
const HtmlWebpackPlugin = require('html-webpack-plugin')
const commonPaths = require('./common-paths')
module.exports = {
entry: commonPaths.appSrc,
output: {
filename: 'bundle.js',
path: commonPaths.appDist
},
target: 'electron-renderer',
resolve: {
extensions: ['.js']
},
module: {
rules: [
{
test: /\.(jpe?g|png|gif|svg|eot|ttf|woff|woff2)$/i,
use: [
{
loader: 'file-loader'
}
]
},
{
test: /\.html$/,
loader: 'html-loader'
}
]
},
plugins: [
new HtmlWebpackPlugin({
template: commonPaths.index
})
]
}