You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As you can see in your forks (MarkForged@6500a64) the spread operator is not a good idea there (yet). At first, the whole thing is not backward compatible, on the other hand it is crashing even in newer versions when webpack is used.
For instance when using frameworks like vue or react inside electron, using your electron-store will already crash with the line const Store = require('electron-store'); as the spread operator will not be recognized correctly (Unexpected token ...)
See electron-userland/electron-webpack#65
The text was updated successfully, but these errors were encountered:
Both Babel and Webpack support object spread and have for a long time. The fact that electron-webpack uses an outdated plugin/preset is not really something this package should concern itself with. I use syntax that works in the Electron version I target. If you use outdated tools, then it's up to you to work around it, sorry.
Ok, maybe the provided links are a little confusing. I use the most recent versions of electron (6.0.11), react (16.9.0) and everything else, so nothing outdated at all. Also, it's not about the spread operator in general, but just the way it is used here (merging options). If you set up a new electron app with react or vue (everything most recent versions ;-), your module will crash as described just be requiring it. If you do not desire to be compatible to this combination of tools, everything is fine. I indeed found a workaround for it: just use another module (electron-settings) instead of this one.
As you can see in your forks (MarkForged@6500a64) the spread operator is not a good idea there (yet). At first, the whole thing is not backward compatible, on the other hand it is crashing even in newer versions when webpack is used.
For instance when using frameworks like vue or react inside electron, using your electron-store will already crash with the line
const Store = require('electron-store');
as the spread operator will not be recognized correctly (Unexpected token ...)See electron-userland/electron-webpack#65
The text was updated successfully, but these errors were encountered: