News for hackers. Stuff that matters.

Ask HN: Why is web tech used to make apps?

Why are so many apps these days glorified web pages running in a browser that pretends not to be one?

- There are much better way to target multiple platforms while sharing code: Xamarin, React Native etc. (and not so good ones like QT/Swing and the like, I guess) - Apps made this way are not native to any of the platorms they run on - best case scenario they replicate platform UI and conventions poorly and with great effort, worst case they look nothing like native apps. Not as bad as Java does but close - HTML/CSS was never meant to be used to create UIs, they are meant to describe and style (hyper)text. It's a necessary evil when targeting browsers where there's no alternative, masochism otherwise - They are also slower and (much) more memory hungry than native apps - Slack happily eats 300+ megs of ram to do very little - They mean having to use JavaScript, instead of a better language with better tooling support - Many/most of the time the use case can be served by an actual web site/app - if you are making something that needs to connect to a database on a remote server to be of any use, why are you making an app to begin with?

Given the above downsides, why are Electron and the like so popular these days?

( 4 comments | 3 points | on HN )
Re:Ask HN: Why is web tech used to make apps? by starptech on Wednesday February 28, 2018 @09:08AM (#16483028)
To have a win-win situation. Most projects are starting with a web project and are expanded to desktop and mobile. If you can reuse your code, technology without any big impacts in performance or UX you will win in any aspect.
Re:Ask HN: Why is web tech used to make apps? by onion2k on Wednesday February 28, 2018 @09:20AM (#16483098)
Most projects are starting with a web project and are expanded to desktop and mobile.

That really isn't true. Most mobile apps don't start out as web projects.

Re:Ask HN: Why is web tech used to make apps? by starptech on Wednesday February 28, 2018 @10:08AM (#16483440)
That's correct but I'm looking it from a completely different angle. Many projects starting with a responsive web app to support desktop and mobile users at once. When the integration isn't great they will use a shell like Electron or PhoneGap so far from a web-based background. The reasons for this are clear:

- Same technology - Reuse all or many code - Frontend people are easier to hire and cheaper

Re:Ask HN: Why is web tech used to make apps? by onion2k on Wednesday February 28, 2018 @08:58AM (#16482967)
Web developers are more common and a lot cheaper.