1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-01-26 18:58:21 +02:00

Fixed module include for Electron app

This commit is contained in:
Laurent Cozic 2017-11-03 18:01:24 +00:00
parent 8a78ee5df6
commit b7e74e4547
3 changed files with 9 additions and 4 deletions

View File

@ -1,11 +1,10 @@
global.joplinLib = __dirname + '/../ReactNativeClient/lib'; // Make it possible to require("/lib/...") without specifying full path
require('app-module-path').addPath(__dirname + '/../ReactNativeClient');
const {app, BrowserWindow} = require('electron') const {app, BrowserWindow} = require('electron')
const path = require('path') const path = require('path')
const url = require('url') const url = require('url')
//const { Logger } = require(joplinLib + '/logger.js'); const { Logger } = require('lib/logger.js');
//console.info(Logger);
// Keep a global reference of the window object, if you don't, the window will // 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. // be closed automatically when the JavaScript object is garbage collected.

View File

@ -95,6 +95,11 @@
"color-convert": "1.9.0" "color-convert": "1.9.0"
} }
}, },
"app-module-path": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/app-module-path/-/app-module-path-2.2.0.tgz",
"integrity": "sha1-ZBqlXft9am8KgUHEucCqULbCTdU="
},
"app-package-builder": { "app-package-builder": {
"version": "1.3.3", "version": "1.3.3",
"resolved": "https://registry.npmjs.org/app-package-builder/-/app-package-builder-1.3.3.tgz", "resolved": "https://registry.npmjs.org/app-package-builder/-/app-package-builder-1.3.3.tgz",

View File

@ -21,6 +21,7 @@
"electron-builder": "^19.43.4" "electron-builder": "^19.43.4"
}, },
"dependencies": { "dependencies": {
"app-module-path": "^2.2.0",
"sqlite3": "^3.1.13" "sqlite3": "^3.1.13"
} }
} }