by idopmstuff · 2y ago · 0 comments
This was an actual debate in the early days of app stores. Facebook was the most prominent company that decided to go with an HTML5 app instead of a native one. Doing so was one of the biggest strategic mistakes they've ever made. Zuck's words, not mine. (https://www.engadget.com/2012-09-11-zuckerberg-html-5-facebo...).
Web apps were slower, had issues dealing with the various browsers and saw less use.
It doesn't seem like the author has done any real research here.
It's wild that I can use a full-featured spreadsheet instantly on the web on my laptop, but on my phone someone wants me to download a 100mb binary to order a pizza.
Google Sheets is now basically a window-sized canvas element, with its own non-native control libraries. I suspect it is not using browser font rendering.
That puts it effectively back into Windows 3.1 days of bitblt graphics, being driven by a difficult to optimize, dynamic language.
It is indeed wild that desktops are good enough to be able to drive such a thing with such performance. However, there is plenty of reason to rely on native frameworks with modern graphics systems.
I suspect there were radically different levels of engineering and optimization that went into Google Sheets vs a typical pizza-ordering app. Even with the same level of engineering, I suspect the pizza ordering app would be larger due to the need to bundle media like pizza and topping images.
If someone invested a lot of time and money into making PWAs work great then there shouldn’t be any technical reasons for why you should choose to develop a native app instead of a PWA. At the moment we are lacking in tooling and language support and also leaving a lot of performance on the table.
I love how easy it is to get up and running with a PWA and most of my front end stuff is using PWAs today. From a technical standpoint it still needs a lot of work from the vendor side though.
The security model of a store is delegated trust and stewardship. There is someone who will review if applications need capabilities, and will provide business penalties for bad behaviors.
The security model of the web is basically a mix of site sandboxing and caveat emptor. There is no guarantee the web app you hit one minute to the next will be the same code base, or belong to the same owner. For example, the same interface has to get consent for notifications from an advertising site which wants to spam you as your corporate chat app.
Chrome had quite a bit more motivation to ignore this or to create a tiered model with PWAs because of Chromebooks, where the model (originally) was web-only development. Google created quite a few one-off API for their systems, and promoted several Chrome-only API as if they were web standards. Even there, this approach was too limiting and eventually Android compatibility was added.
Apple has started to add some additional app-useful features like notifications, but behind the 'Add to Home Screen' option. One could look at this like promoting a website to an 'app' on the phone, partially because that gives a consistent way for the user to understand permissions and privacy implications for both native and web code.
There are plenty of people who wish there was a better mechanism on iOS than the current add to Home Screen flow, but it is highly unlikely to become more streamlined because of abuse potential.
I think Stadia worked over the browser to deliver AAA games. There’s obviously a whole bunch of missing technology needed to deliver (and later patch) huge web apps locally though. Plus annoying browser limits like the hard kill based on memory usage in mobile Safari.
A tonne of effort has gone into making spreadsheets work on the web; both in the browsers as well as the spreadsheet apps themselves.
The fact that the web works as well as it does is a huge feat of engineering, but in no way indicative of there being no technical reason that native apps can be better.
Many apps are fine as web apps without any OS support at all.
yes, yes there is. HTML/JS is a bastard to parse. it takes a fucktonne of resources to actually figure out how to render a box. Go and fire up a windows 95 box, with 133mhx of pentium III goodness. THen make a VB6 app that animates boxes/shows images.
Look how fucking fast it can do it (and vb6 wasn't a fast language)
Or, more easily, render a web page on the original raspberry pi-b, try and play video in a browser, do some sort of animation.
It lags like a fucker. Use py-game (you know python with its 50% "what fucking type is this?" tax) and you can run animations at 60fps.
The web is slow, its just moore's law has shielded us from it.
Parsing is a tiny fraction of the time that a Web browser spends, and the various native resources are on the same level of complexity. TrueType hinting instructions from the 90s are of a similar complexity to the HTML 5 parsing spec.
> Go and fire up a windows 95 box, with 133mhx of pentium III goodness. THen make a VB6 app that animates boxes/shows images.
This will easily run at the same framerate on a modern Web rendering stack.
> Or, more easily, render a web page on the original raspberry pi-b, try and play video in a browser, do some sort of animation.
Browsers on the Raspberry Pi B weren't accelerated, due to various reasons including Broadcom having (at the time) the worst GPU driver situation imaginable. You should compare against modern accelerated browsers (by "modern" meaning "within the last 20 years on mainstream OS's").
> It lags like a fucker. Use py-game (you know python with its 50% "what fucking type is this?" tax) and you can run animations at 60fps.
Web apps have been able to run animations at 60 FPS for decades. (As an aside, the performance difference between CPython and native code is far more than 50%.)
to animate anything, you are looking at 100x cost in power.
This means that you will drain the battery much much faster than with native.
The solution is not using webtools, its making native much more open/portable. you know like java was supposed to be (kinda like how APKs are now. )
The article which you linked to is from 2012; it pertains to the performance of Facebook's web client in 2010, when run on mobile devices in 2010.
Most apps today can be implemented as progressive web apps, without any user experience penalty. Instead, they are built with tools that lock developers into a platform of one type or another. That's because some handset manufacturers prioritize the platforms that have lock-in, such as the App Store and iMessage, over the platforms that do not, such as the web and RCS. It is not because the web is somehow a bad platform for apps.
If you want FaceTime to call your mom on her headset when your watch detects a spike in your heart rate, then yes, you may want to write a native app to do that. But Sudoku, Pandora and the McDonald's app can live on the web, and so can most of the rest.
yeah nah,
the FT, the bastion of PWAs because of the "if you have a subscription, we'll take 25% of that thanks" flipped to native almost as soon as the rules changed.
why? because the user experience sucked bollocks. It was slow, memory hog, and a massive massive bollockache to maintain. Don't get me wrong, thats not because they were bad at making the web app, its because the tech isn't up to scratch.
https://enterprise.ft.com/en-gb/blog/ft-app-now-available-io...
This says they just wrapped their web app in a native app, like a web view, so they could then use system features that their web apps couldn't access. So are you sure you're not using a web app after all? You might be using the same tech as you were before.
I don't think web apps are the future, but I also don't see why there can't be a more protected mode/sandbox for non app store sourced content to run in. Nobody has solved this yet - why can I visit pretty much any website and (mostly) be completely safe, yet I can't install any old random APK?
Hell, it should be possible to jump from the web into native code with a single click by now, why tf not. The only good thing the app stores are good for is to serve up apps that are "more trusted" (even tho app stores constantly have a couple bad actor apps on em) as well as centralised place to easily find stuff (the reason people use Google).
I guess the real problem with sandboxing/permissions systems is that users don't know what's good for them; my Tiktok loving friends would just hit "yes, yes, yes" to any dialog that says "TT wants to know your shoe size".
Apps like Facebook are constantly preloading data in the background to fill your feed immediately on app launch. 99pct of web apps would not have that need fortunately.
And let's be real, FB went with native apps because they could quietly hide app permissions that a web browser would warn you about with a big scary dialog window. That would be catastrophic for the world's biggest targeted advertising company. They ran a full page ad when Apple started requiring app tracking disclosures on iOS.
The cellphone duopoly is using their power to make sure the web cannot match native. That's how they make their gobs of money that hasn't been subject to real competition. They get a free rake off of the innovation of others.
If you allow web downloads of apps with no store and no scare wall, companies will develop better / native-level browsers. They'll happily chip away at Google and Apple.
With WASM, we have the tech. As soon as it goes multithreaded, it's game over for native apps. (So long as the DOJ clears the runway and forces these companies to allow fair competition and progress.)
I agree with your overall point, but this really isn’t a fair categorisation of Safari. It’s a fast, modern, efficient browser, and a lot of the stuff it doesn’t support is only supported in Chrome.
I concede it does lag behind Firefox in terms of supported web features, but only very slightly, and if you compare pre-release versions, that gap narrows even more (using the Caniuse browser scores as a rudimentary measure).
And because the browser is also hard coded to the iOS version, it has the slowest update rate of all modern browsers.
Yes. The problem is that may python libraries involve compilation of c, rust or other native languages that themselves need a WASM toolchain configured to cross compile to WASM correctly, and potentially patches to support the platform.
This toolchain support is coming though. See pyodide.org for one example.
But if you just want to grab python.wasm from somewhere and run it on the cli, take a look at something like https://github.com/vmware-labs/webassembly-language-runtimes...
Of course you can run the python interpreter in WASM[1], but that will be at a significant performance disadvantage to the native javascript interpreter, and it's also something that has to be loaded every time you load the website.
YC made a good bet here.
That was over a decade ago. Back then, Youtube was still using Flash (the HTML5 beta was only around a year old), JavaScript engines were way slower, Chrome was still using WebKit... HTML5 today is not what it was in 2011.
Even putting aside the fact that the web was "slower" in part because of the decisions mentioned in the article that are intended to encourage native app design, it's not a foregone conclusion that the same is true today.