Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save gdonega/5dc2ce785a342d40816bd35c3a6eb76c to your computer and use it in GitHub Desktop.
Save gdonega/5dc2ce785a342d40816bd35c3a6eb76c to your computer and use it in GitHub Desktop.
...
let mainConfig = {
entry: {
main: path.join(__dirname, '../src/main/index.js')
},
externals: [
...Object.keys(dependencies || {}),
{'electron-debug': 'electron-debug'}
],
module: {
rules: [
{
test: /\.(js)$/,
enforce: 'pre',
exclude: /node_modules/,
use: {
loader: 'eslint-loader',
options: {
formatter: require('eslint-friendly-formatter')
}
}
},
{
test: /\.js$/,
use: 'babel-loader',
exclude: /node_modules/
},
{
test: /\.node$/,
use: 'node-loader'
}
]
},
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment