leo / electron-next

Build Electron apps using Next.js
https://github.com/leo/site/blob/beef3a7dc1dfd435a9d8377e3b1b59761ccb7fc7/pages/2017/electron-next.js
MIT License
546 stars 41 forks source link

Disables all main process errors #23

Open 2JJ1 opened 5 years ago

2JJ1 commented 5 years ago

When including, "await prepareNext('./renderer')", all errors that typically appear in Electron main's error pop up no longer appear. Rather the Electron process just exits and gives no information regarding the error.

For example,

require('../invalid/file/path.json')

That code in electron's main would just flat out exit the app and the console says there was a lifecycle error. The error log it gives does not help. When removing "await prepareNext('./renderer')", I can read the error just fine from Electron's error pop up window.