2019-06-16 00:41:43 +02:00
|
|
|
const path = require('path');
|
|
|
|
|
|
|
|
module.exports = {
|
2019-06-30 01:18:21 +02:00
|
|
|
mode: 'production',
|
2020-11-12 21:09:43 +01:00
|
|
|
entry: path.resolve(__dirname, '../src/renderer.ts'),
|
2019-06-16 00:41:43 +02:00
|
|
|
target: 'electron-renderer',
|
|
|
|
output: {
|
2020-11-12 21:09:43 +01:00
|
|
|
path: path.resolve(__dirname, '../frontend'),
|
2019-10-02 22:42:27 +02:00
|
|
|
filename: 'bundle.js',
|
2019-06-16 00:41:43 +02:00
|
|
|
},
|
|
|
|
module: {
|
|
|
|
rules: [
|
|
|
|
{
|
|
|
|
test: /\.svelte$/,
|
2020-04-10 04:38:03 +02:00
|
|
|
loader: [
|
2019-06-16 00:41:43 +02:00
|
|
|
{
|
|
|
|
loader: 'svelte-loader',
|
|
|
|
},
|
|
|
|
],
|
|
|
|
},
|
|
|
|
{
|
|
|
|
test: /\.ts$/,
|
|
|
|
loader: [
|
|
|
|
{
|
|
|
|
loader: 'ts-loader',
|
2020-04-10 04:43:32 +02:00
|
|
|
options: {
|
|
|
|
configFile: path.resolve('tsconfig.renderer.json'),
|
|
|
|
},
|
2019-06-16 00:41:43 +02:00
|
|
|
},
|
|
|
|
],
|
|
|
|
},
|
2019-07-26 23:05:29 +02:00
|
|
|
{
|
|
|
|
test: /\.mjs$/,
|
|
|
|
include: /node_modules/,
|
|
|
|
type: 'javascript/auto',
|
|
|
|
},
|
2019-06-16 00:41:43 +02:00
|
|
|
],
|
|
|
|
},
|
|
|
|
resolve: {
|
2019-10-05 03:09:34 +02:00
|
|
|
extensions: ['.ts', '.js', '.mjs'],
|
2019-06-16 00:41:43 +02:00
|
|
|
},
|
|
|
|
};
|