Open pixelass opened 6 months ago
So...
I moved all those packages to devDependencies and it seems to just work. (tested dev and prod/packaged)
{
"electron-context-menu": "^4.0.0",
"electron-dl": "^4.0.0",
"electron-serve": "^2.0.0",
"electron-store": "^9.0.0"
}
I'll keep this open because all nextron examples explicitly list electron-store and electron-serve inside dependencies
and I'm not sure why that causes issues. Seems awkward to me but there's probably a good explanation for it.
@pixelass
Sorry for late reply.
I strongly agree with you. I'll try to investigate it :)
@pixelass
Finally, I found the solution! It works fine in my place :)
I'll update nextron which supports ESM next month!
@saltyshiomix Any update on this?
About a week ago @sindresorhus released some breaking changes on various electron packages.
This seems to not work with nextron. (we already use electron v30)
Some packages that are affected include: (these are the ones we use in "Captain")
As the changes seem to only affect the ESM only aspect and we don't see any crucial need to update ATM it's not urgent but should be tackled rather sooner than later.
@saltyshiomix Any info on how we can get support on this? (We are willing to help on this one as we would love to stay up to date)
I've gained a ton of additional experience with electron in the past half year and very comfortable trying to figure this out but would appreciate some brainstorming as I'm sure you already have some great ideas on moving forward ❤️)
EDIT
After closer inspection I noticed that only packages that are included in "dependencies" have an issue with ESM-only packages. Packages that are in "dev-dependencies" (like globby or execa) work perfectly