const base = require('./base')
const merge = require('webpack-merge')
const ExtractTextPlugin = require('extract-text-webpack-plugin')

const renderer = {
	entry: './src/client.ts',
	output: {
		filename: 'renderer.js'
	},
	target: 'electron-renderer',
	module: {
		rules: [
			{
				test: /\.css$/,
				use: ExtractTextPlugin.extract({
					use: 'css-loader'
				})
			},
			{
				test: /\.woff2(\?[a-z0-9=&.]+)?$/,
				loader: 'file-loader',
				options: {
					name: 'fonts/[name].[ext]?[hash]'
				}
			},
			{
				test: /\.(ttf|eot|svg|woff)(\?[a-z0-9=&.]+)?$/, // Needs to be used with caution
				loader: 'ignore-loader'
			}
		]
	},
	plugins: [new ExtractTextPlugin('styles.css')]
}

module.exports = merge(base, renderer)

@@ -127,16 +127,73 @@
 plugin')
+%0Aconst CopyWebpackPlugin = require('copy-webpack-plugin')
 %0A%0Aconst 
@@ -397,16 +397,17 @@
 %09%09%09use: 
+%5B
 'css-loa
@@ -406,24 +406,47 @@
 'css-loader'
+, 'resolve-url-loader'%5D
 %0A%09%09%09%09%7D)%0A%09%09%09%7D
@@ -469,13 +469,15 @@
  /%5C.
+(
 woff2
+)
 (%5C?%5B
@@ -693,14 +693,12 @@
 r: '
-ignore
+skip
 -loa
@@ -726,16 +726,19 @@
 ugins: %5B
+%0A%09%09
 new Extr
@@ -764,16 +764,111 @@
 es.css')
+,%0A%09%09new CopyWebpackPlugin(%5B%0A%09%09%09%7B%0A%09%09%09%09from: './src/index.html',%0A%09%09%09%09to: 'index.html'%0A%09%09%09%7D%0A%09%09%5D)%0A%09
 %5D%0A%7D%0A%0Amod

Fix fonts