-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Run app.setAppPath() with the right path #78
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems legit, would like to see more use of semicolons even if these files aren't linted for some reason 😆
|
2bd1028
to
f95f15c
Compare
Added linting and testing to |
🎉 This PR is included in version 1.4.2 🎉 The release is available on: Your semantic-release bot 📦🚀 |
we are getting an error on missing app #80 so i tried to add a pull request for it but we dont have even electron install in this package here is the #81 what do you think about it @felixrieseberg |
Electron will set the
appPath
by looking forpackage.json
. When using this module, this will end up being insideapp.asar
.The problem is that from point on forward, APIs like
webContents.loadFile()
will be using thisapp.asar
as the application's root.webContents.loadFile('renderer/index.html')
will no longer work, since that file won't be insideapp.asar
- it'll actually be insideapp-x64.asar
orapp-arm64.asar
.Users can handle this problem in user land, but I assume that you need to know Electron pretty darn well. I propose that we fix this directly in the default asar. The same issue also exists with
app
folders, which this PR fixes, too.