Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Yes, and as you can see, things are not that trivial.

At the high level, you can approach it in two ways.

- WebView to localhost would be the first solution but is inherently not secure (or needs lot of work to make it so, and still)

- Another way is that the app container that bootstrap the webview have a scheme to serialize/deserialize JSON message between the JS environment and the app container (in rust in this case). And that is what Tauri nailed down.

In fact, Tauri also supports localhost, in prod and dev. And where it becomes insanely good is that for dev, you can use localhost and use something like servor to have hot reload when you can UI code, and when its time to pack your app for distribution, it bundles those html assets part of the binary.

Anyway, some Rust marvels are out there, and this is one of them.

(btw, this is for desktop applications, not browser extensions)



Yeah, it does fill a gap but what appears to be a temporary one. Web apps can already be installed like an application, and now include window-control-overlay amongst other things. At one point I think Safari was slacking, but may have mostly caught up. As you mentioned, once an option exists for passing messages from browser to a native app (similar to Native Messaging but for Web Apps) then it would make more sense IMO to just use the browser's existing support.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: