Skip to content

Commit

Permalink
[with-electron] Upgrade electron & transpile for the installed version (
Browse files Browse the repository at this point in the history
#8399)

* Upgrade packages

* Transpile for the installed electron version

* standard --fix
  • Loading branch information
merceyz authored and Timer committed Aug 20, 2019
1 parent a271ab3 commit 3fa7c12
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 3 deletions.
6 changes: 3 additions & 3 deletions examples/with-electron/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"scripts": {
"start": "electron .",
"build": "next build renderer && next export renderer",
"dist": "npm run build && build --dir"
"dist": "npm run build && electron-builder --dir"
},
"build": {
"asar": false,
Expand All @@ -18,8 +18,8 @@
]
},
"devDependencies": {
"electron": "^4.1.0",
"electron-builder": "^20.39.0",
"electron": "^6.0.2",
"electron-builder": "^21.2.0",
"next": "latest",
"react": "^16.8.4",
"react-dom": "^16.8.4"
Expand Down
16 changes: 16 additions & 0 deletions examples/with-electron/renderer/babel.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
const { devDependencies } = require('../package.json')

module.exports = {
presets: [
[
'next/babel',
{
'preset-env': {
targets: {
electron: devDependencies.electron.replace(/^\^|~/, '')
}
}
}
]
]
}

0 comments on commit 3fa7c12

Please sign in to comment.