feat: add support for loading webpack assets via custom protocol#3511
Draft
MarshallOfSound wants to merge 1 commit intomainfrom
Draft
feat: add support for loading webpack assets via custom protocol#3511MarshallOfSound wants to merge 1 commit intomainfrom
MarshallOfSound wants to merge 1 commit intomainfrom
Conversation
This is more secure than using file:// and aligns us with Electron on the intention to stop making the file:// protocol special and powerful. Fixes #3508
| const STATUS_CODE_FORBIDDEN = 403; | ||
| const STATUS_CODE_INTERNAL_SERVER_ERROR = 500; | ||
|
|
||
| protocol.registerFileProtocol(config.protocolName, (request, cb) => { |
There was a problem hiding this comment.
Isn't this call deprecated in the recent Electron versions and instead one should use "handle"?
Member
Author
There was a problem hiding this comment.
Yeah, but it's not gonna be removed any time soon and we can migrate at some point in the future. This at the moment is more performant that handle for complicated reasons so to avoid issues around that we'll use the deprecated API for a bit
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is more secure than using file:// and aligns us with Electron on the intention to stop making the file:// protocol special and powerful.
Fixes #3508
Testing this is kinda a nightmare but I think it works, leaving as draft till I'm 100% sure tho