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

This looks like a nice solution to save some time for cross-platform developers on .NET Core. I'm sure we're going to see a lot more of this once the new Chromium version of Edge is released mid Jan 2020 (which will include the new webview2 component).

If you don't want to add an external library to do this, or your source is already platform dependent, just use the default web view component of each operating system (WebBrowser for Windows, WKWebView for macOS and WebKitGTK+2 for Linux) like this library does.

To work around some of the ugliness of the old IE rendering engine used in the current WebBrowser control on Windows, just add this meta tag to the HTML file to ensure it uses the new versions of IE to render the UI: <meta http-equiv="x-ua-compatible" content="ie=edge">

You can disable most non-native app behavior in JS (like scrolling or the default right click context menu using javascript). You're then free to use whatever front end framework you want and pass data between the web-app and native code using JSON.



I think setting x-ua-compatible ie=edge doesn't mean use the Edge EdgeHTML engine - it means enabling "Edge mode" in IE, which means "the latest available version of IE" and you end up with IE10 or IE11.

EdgeHTML can be embedded, but only using the WinRT API, not the ActiveX WebBrowser control.


Welcome to the web, where browsers are named after existing browser concepts in as confusing a way as they can come up with. “You know how browsers have chrome around the web content, and how that’s the accepted term of art? Let’s call our browser Chrome!” “You know how we can tell IE to run in edge mode? Let’s call our replacement browser, which IE compatibility mode won’t be able to use, Edge!”


Yes this is still a very alpha package, fallback support for non chromium-based edge has not yet been implemented.




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

Search: