Hacker News new | ask | show | jobs
by tylerlarson 3586 days ago
A few other people have mentioned JavaScript and HTML but in my experience HTML and CSS support varies wildly between platforms and as applications become larger it is difficult to tune the performance of your running application. Also the implementation of the base code for HTML tags and what CSS properties can do are inaccessible to JavaScript making many task much harder than they would be in other environments where you can simply extend or introspect the internals.

But if you want something to run everywhere including web browsers, JavaScript is the only realistic option. So we make do. My current approach is to rely on HTML/CSS and React/React Native for the easy stuff and everything else is rendered in the Canvas tag with lots of JavaScript to bend the platforms into doing what you want.

In the past I have taken similar approaches by using things like Ejecta but the android support for this is lacking and now that WKWebView has addressed many of its issues, using standard WebViews within native containers is fast enough on mobile.

On desktop, Electron, NW or the other things like this can fulfill the same setup.

People will complain about performance which was a really big issues a few years ago but today the difference isn't large enough that it can't be worked around and most of the fear is in people heads. Most environments have web workers, and webgl, and JavaScript that has a JIT, and many new things like Web Assembly and SIMD should be available in the coming years making these platforms even more viable.