Skip to content

Commit

Permalink
fix running electron on yoman generated app
Browse files Browse the repository at this point in the history
  • Loading branch information
andrey-skl committed Jul 22, 2019
1 parent 9b940f1 commit 0ed785b
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 12 deletions.
24 changes: 13 additions & 11 deletions packages/generator/app/templates/karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,17 +71,19 @@ module.exports = config => {

// start these browsers
// available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
browsers: ['Electron'],

electronOpts: {
show: false,
skipTaskbar: true,
height: 1024,
width: 768,
webPreferences: {
pageVisibility: true
},
commandLineSwitches: ['--no-sandbox']
browsers: ['CustomElectron'],

customLaunchers: {
CustomElectron: {
base: 'Electron',
browserWindowOptions: {
show: false,
skipTaskbar: true,
height: 1024,
width: 768
},
flags: ['--no-sandbox']
}
},

// Continuous Integration mode
Expand Down
2 changes: 1 addition & 1 deletion packages/generator/app/templates/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
"eslint": "^5.16.0",
"karma": "^4.2.0",
"karma-chai-plugins": "^0.9.0",
"karma-electron-launcher": "^0.2.0",
"karma-electron": "^6.3.0",
"karma-mocha": "^1.3.0",
"karma-sourcemap-loader": "^0.3.7",
"karma-teamcity-reporter": "^1.1.0",
Expand Down

0 comments on commit 0ed785b

Please sign in to comment.