This repository has been archived on 2021-06-30. You can view files and clone it, but cannot push or open issues or pull requests.
2019-02-09 01:34:04 +00:00
|
|
|
require('dotenv').config();
|
|
|
|
const path = require('path');
|
|
|
|
const webpack = require('webpack');
|
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
mode: process.env.NODE_ENV,
|
|
|
|
|
|
|
|
entry: ['@babel/polyfill', './src/renderer.js'],
|
|
|
|
output: {
|
2019-04-01 17:50:15 +00:00
|
|
|
path: path.resolve(__dirname, 'build'),
|
2019-02-09 01:34:04 +00:00
|
|
|
filename: 'bundle.js'
|
|
|
|
},
|
|
|
|
module: {
|
|
|
|
rules: [
|
|
|
|
{
|
|
|
|
test: /\.jsx?$/,
|
|
|
|
exclude: /node_modules/,
|
|
|
|
use: {
|
|
|
|
loader: 'babel-loader',
|
|
|
|
}
|
|
|
|
}, {
|
|
|
|
test: /\.s?css$/,
|
|
|
|
use: [
|
|
|
|
{ loader: 'style-loader' },
|
|
|
|
{ loader: 'css-loader' },
|
|
|
|
{ loader: 'sass-loader' }
|
|
|
|
]
|
|
|
|
}, {
|
|
|
|
test: /\.(png|jpg|svg)$/,
|
|
|
|
use: [{ loader: 'file-loader' }]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
devtool: 'inline-source-map',
|
|
|
|
target: 'electron-renderer',
|
|
|
|
devServer: {
|
2019-04-01 17:50:15 +00:00
|
|
|
contentBase: path.join(__dirname, 'build'),
|
2019-02-09 01:34:04 +00:00
|
|
|
compress: true,
|
|
|
|
port: process.env.PORT
|
|
|
|
}
|
|
|
|
};
|