-
Notifications
You must be signed in to change notification settings - Fork 30
fix: resolve issues with fetching local assets when serving files from the file protocol #514
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: resolve issues with fetching local assets when serving files from the file protocol #514
Conversation
…m the file protocol
|
Thanks! I guess this would not work with Image workers set to Because then it'll fall back to: |
|
I need to test that with that setting. I am guessing that it would fail because it would be using fetch which does not support the
|
|
@vonvick yes we should use XHR there as well, to ensure we can load local files on the web worker as well. To my understanding there are no performance implications between XHR and fetch when loading simple images. For (large) JSON files, fetch supposedly is faster Also we need to add license headers for the new helper file you created ( Other than that, this looks good to me! |
|
Loads of test failing though, likely because something is tripping the MSDF Font parsing. Had blurry fonts before if the alpha channel was incorrectly set. And there seems to be a mismatch now with loading some textures. |
|
@wouterlucas it did fail with the ImageWorker set to 0. But I have fixed it and now it works with or without the image worker being used. |
michielvandergeest
left a comment
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.
LGTM! 🔥
|
we should really rename |
What does this PR do?
This PR fixes the issue where the assets in locally packaged apps are unresolved and fail to load. Now the local assets are loaded successfully and served to the app.
How has this been tested?
This has been tested locally on various WebOS devices