-
-
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
binary support #3212
Comments
Without knowing your use case, I can only suggest https://wails.io/docs/guides/dynamic-assets/ |
|
There are certain scenarios where json encoding and decoding is costly, such as photoshop and video editing software. While the use of binary with Uint8Array in websockets can temporarily handle this, it would be nice to have binary support built into the binding. |
SharedBuffer would be good. What about Mac and Linux though? |
There are no such things on those platforms. The only thing that works there is streaming responses through the AssetServer as you already mentioned (https://wails.io/docs/guides/dynamic-assets/) |
Please be aware, Websockets don't work over the custom scheme used in-app, unless you are starting your own http server on the network stack. |
Would be awesome if sockets were used for the IO between the Backend and Frontend. Pushup does it this way for golang htmx projects. https://github.com/adhocteam/pushup/blob/main/_runtime/cmd/main.go#L29 |
@gedw99 Opening unix sockets or ports on the network stack is probably not a feature people want to see in a default Wails app. That would allow to intercept traffic from backend/frontend relatively easy, that's why the AssetServer is not bound to the network stack and uses IPC. But if someone wants to do that, that is pretty easily doable with just a couple of lines in Go to start a http server and use that in your frontend. |
Any update on this one? |
Is your feature request related to a problem? Please describe.
I use wails to transmit binary image streams, but I found that if I bind the method of transmitting binary, wails will automatically base64 encode the binary. Is there a more efficient method?
Describe the solution you'd like
such as this: https://github.com/MicrosoftEdge/WebView2Feedback/blob/main/specs/SharedBuffer.md
Describe alternatives you've considered
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: