dioxus
                                
                                
                                
                                    dioxus copied to clipboard
                            
                            
                            
                        C:// and file:// paths are rejected by the webview
Problem
If you use an absolute path on dioxus desktop on windows, it will be blocked by the webview and the asset will not resolve.
Steps To Reproduce
Steps to reproduce the behavior:
- Find an absolute path to an image on windows
 - Use an image element: `img { src: "yourpath" } (where yourpath is on a different drive on windows)
 - Run the app
 
Expected behavior
Dioxus should either provide a different way to link to absolute paths on windows or fix absolute paths
Environment:
- Dioxus version: 
master - Rust version: 
nightly - OS info: Windows
 - App platform: 
desktop 
Questionnaire
- [ ] I'm interested in fixing this myself but don't know where to start
 - [ ] I would like to fix and I have a solution
 - [ ] I don't have time to fix this right now, but maybe later
 
Using dioxus://Drive:/yourassetpath also doesn't work because the custom wry protocol only receives the url after the drive, so we cannot find the asset the user wants
Looked into this - the real problem is that when passing a path that includes the drive, the webview just rejects it
Not allowed local resource
We could/should provide some way of accessing off-drive paths - either via dioxus:// and some custom encoding or some other solution.
The correct way of specifying an URL with a custom protocol with wry on Windows is http://protocol.path
So for example this will work: http://dioxus.c/Users/MyUser/Desktop/myimage.png. It's annoying to have to do it in a different way between linux and Windows, but it works. I'm not sure whether this is wry or Webview2's fault