summaryrefslogtreecommitdiff
path: root/test/application
diff options
context:
space:
mode:
Diffstat (limited to 'test/application')
-rw-r--r--test/application/src/main.js9
-rw-r--r--test/application/webpack.config.js4
2 files changed, 12 insertions, 1 deletions
diff --git a/test/application/src/main.js b/test/application/src/main.js
index bf2144d..d030f18 100644
--- a/test/application/src/main.js
+++ b/test/application/src/main.js
@@ -1,11 +1,18 @@
// Modules to control application life and create native browser window
import { app, BrowserWindow } from 'electron'
-// import { mainReloader, rendererReloader } from '../../../dist'
+import path from 'path'
+
+import { mainReloader, rendererReloader } from '../../../dist'
// Keep a global reference of the window object, if you don't, the window will
// be closed automatically when the JavaScript object is garbage collected.
let mainWindow
+const dir = path.join(app.getAppPath(), 'temp')
+
+mainReloader(dir)
+rendererReloader(dir)
+
function createWindow () {
// Create the browser window.
mainWindow = new BrowserWindow({
diff --git a/test/application/webpack.config.js b/test/application/webpack.config.js
index c1d23e8..6203400 100644
--- a/test/application/webpack.config.js
+++ b/test/application/webpack.config.js
@@ -13,6 +13,10 @@ const mainConfig = {
path: path.resolve(__dirname, 'dist'),
filename: '[name].js'
},
+ node: {
+ __dirname: true,
+ __filename: true
+ },
plugins: [
new CleanWebpackPlugin()
],