-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
strange behavior when ajax local files #167
Comments
File access is blocked on browser for security reasons In cef I'm using its Schemehandler instead of a localhost server: Looks like its not working correctly in this case 🤔, will need to look over it again. Is it possible for you to share the wallpaper? |
Ok, I'll have a look. |
after testing, i found that error only happen on i think.....may be add a polyfill that set test log fetch("models/lingbo//lingbo.model3.json").then(alert("hi"));
>>>VM221:1 Fetch API cannot load localfolder://index.html/models/lingbo//lingbo.model3.json. URL scheme "localfolder" is not supported. |
I'm not very familiar with web technologies, let me know if it works. I'll check the scheme handler code again when I get the time. In the future, I do plan to add support for Webview2 (Edge) #160 with localhost server when it hits stable(.net version), that should resolve this automatically. |
After testing , it work!🤔
fetch=WHATWGFetch.fetch; !❗it not the best way to fix it,but it's work❗ ! |
Nah keep it open, this workaround won't be required in the future. |
Try registered your scheme with IsFetchEnabled set to true. http://cefsharp.github.io/api/86.0.x/html/P_CefSharp_CefCustomScheme_IsFetchEnabled.htm |
Thanks, it works now! |
Great 😄 The built in https scheme has fetch enabled, it's a standard feature. Generally speaking it's fine to enable. It's not so much as it's deliberately disabled by default, it's more the default wasn't updated when fetch support was added. |
Got it, appreciate the help. |
@KAIYOHUGO Beta build is up, you can check if it works: |
its ok now, tks guys👏👏 |
Describe
when live2d web sdk try to load model.json happend (read log below
To Reproduce
Steps to reproduce the behavior:
Expected behavior
when it load model.json throw a error
2020-10-19 15:59:41.6720|INFO|livelywpf.Core.WebProcess|CEF:Fetch API cannot load localfolder://index.html/models/lingbo//lingbo.model3.json. URL scheme "localfolder" is not supported.
Screenshots/Video
Desktop (please complete the following information):
Additional context
if u set live2d web sdk demo as a web not a local files everything is ok
Log file
The text was updated successfully, but these errors were encountered: