Live data from Hacker News

Write code for the web

mrmr.io

221–230 of 364 posts

Re: Write code for the web

#221

Early on, I made the choice to not to invest in learning native mobile development. I focused all my limited time on the web, and I think that, for once, I made the right choice. Today, one can build amazing stuff for the browser. And, in my very humble opinion, the vast majority of apps should've been WebApps — except for maybe Uber, Google Drive, and games. I worked in the journalism business, and, in my country, t…

I just wish Web wasn't such a frustrating development experience. While it has improved leaps and bounds in the last decade, I still find it to be suboptimal when compared to native offerings. Most of that frustration comes down to tooling and more specifically TypeScript. I'm not sure how to succinctly express my pain here but I have found generally that I wrestle with the type system in TypeScript far more than nat…

I came from the much cleaner, simpler type system of AS3, but I don't really see a problem with the complexity of TS. There are a lot of aspects of its type system I will probably never use... but I don't have to. I've written a lot of fairly complex business and game software for the web, and never found myself reaching for a conditional type. Meanwhile, keyof and union types are handy for autocomplete hints. And to me that's all TS is really about. It's just there to make large scale javascript less of a dynamic, chaotic, untyped mess.

Re: Write code for the web

#222
post #73

Earlier quoted context omitted.

Google and Apple should be regulated to offer the same functionality and performance to the web. Their grip on the most important technology of the century is astounding and harmful. Honestly first-class web mobile installs without hoops and scare walls would be the thing to strive for.

I'm not aware of any scare walls on iOS. On Android is a site is installable a little banner is supposed to pop up and ask if you want to install it. On iOS one has to open the site's share sheet and pick an install option nestled in there somewhere. I suppose that counts as a hoop, but how else would you surface the functionality without it being invasive and annoying for most users? I think a more pertinent problem…

> devs don't want to distribute their apps as PWAs because Apple deletes saved data at unpredictable intervals

Does anybody know what the current situation in iOS looks like? I researched this recently and the information is conflicting. The OPFS data (Origin Private File System, which is the new storage API for PWAs and is supported in Safari) is supposed to not be deleted without explicit user confirmation, but what this confirmation looks like is unknown (is it just the usual delete Safari history button?) and I didn't run any experiments. However I've seen someone claiming Apple separates a website and it's installed PWA's storages. This is reinforced by the fact that I can see the storage space each PWA takes in Settings (which was oddly not updated when a PWA using OPFS used some more storage). However I just deleted that PWA but there were no special prompts, just the usual native app deletion prompt, absent of the usual phrase "Deleting this app will delete its data.", only the phrase "Do you want to delete this bookmark." was present.

Re: Write code for the web

#223

Early on, I made the choice to not to invest in learning native mobile development. I focused all my limited time on the web, and I think that, for once, I made the right choice. Today, one can build amazing stuff for the browser. And, in my very humble opinion, the vast majority of apps should've been WebApps — except for maybe Uber, Google Drive, and games. I worked in the journalism business, and, in my country, t…

> except for maybe Uber, Google Drive, and games I understand Drive working better as a native app; it needs to be able to provide a virtual filesystem to the OS and do background syncing and such. But why Uber? Uber has (or maybe had) a mobile site that works fine for requesting rides and basically everything the app can do. I don't see what value Uber being a native app adds for the user. The same goes for most mob…

> Of course, Apple's lackluster support or PWAs doesn't help.

Holding the web back is entirely intentional and makes strategic sense from Apple's point of view. They're well aware that a majority of apps would work perfectly fine as web apps -- but that also removes Apple from the equation. Only allowing Safari on iOS and intentionally gimping it solves the problem.

I mean, I can't even blame them. Can't lose out on that sweet 30% cut, y'know?

I'm only disappointed that legislation took this long to catch up to their shenanigans, and only in the EU.

Re: Write code for the web

#224
post #21
post #2

Apple provides thousands of APIs to make developing on the platform easier, has created their own programming language that integrates nicely with the platform and has a fully integrated IDE that works with both above. Sure, buddy… They don’t care about you unless you develop for their platform. And who can blame? The above is a terribly expensive and timely investment.

Swift is great, but the vast majority of apps really don't need to be lovingly hand-crafted for each platform, and Swift is (currently) a bad choice for anything non-Apple. Personally if I were working on mobile stuff, I'd be looking at .NET MAUI.

I'm not sure why you think MAUI is a great choice considering its current status. There is a huge lack of learning resources, a very tiny community, and very few-to-none successful applications built entirely using MAUI at this point. There isn't any strong guidance or opinionated advice for how to architect or scale your app from Microsoft, either. Avalonia is a much better choice if you must use .NET, but outside of people who really, really like C# or have legacy apps they want to migrate, I don't think either will be very good choices for new greenfield apps. If anything, Microsoft has been signaling that Blazor Hybrid is what you should be using, and while it does use the same core technology under the hood, it is much more at home for C# developers who have been doing ASP.NET which has far more developers than WPF or Xamarin ever did.

Re: Write code for the web

#225
post #122

Earlier quoted context omitted.

Google and Apple, both of whom make web browsers as well as OSes and could therefore cheat loads with anything like that. Of all the places to find someone conflating the companies with the operating systems Android and iOS . But even then… > same functionality > Honestly first-class web mobile installs without hoops and scare walls would be the thing to strive for. Coming to a future near you: npm install rm_minus_r…

One word: sandboxing.

Is one of the ways they make browsers and app store apps more secure, that that is dissimilar to old school installation.

Re: Write code for the web

#226
When I think about it, it astonishes me that there are people in the world who take Apple's developer tools, and make some really beautiful and useful iOS apps. I've tried on and off since high school and have never been able to do it. I started in high school with Xcode and Objective-C, which is a very difficult language to work with (being not that far removed from C/C++). When they moved to Swift I thought "okay finally, now I can make some iOS apps!", but Swift also proved to be a bit of a strange language, it's like the pendulum swung in the opposite direction- Apple was trying to cater to non-devs with it. So we ended up with something that was sort of like Python but still retained some elements from Objective-C.

Of course during this entire time span, Xcode remained a garbage IDE. That's probably the main hindrance for devs and would-be devs. Swift can be navigated, Xcode is a black hole of doom.

Re: Write code for the web

#227

This author seems confused about something that he, himself explains. The reason that Apple doesn't care about developers is that they have created such a walled garden cult w/ users that developers are forced to produce products for their platform or they lose half their market -- or more. At my day job in mobile game development (for a small studio inside a large company), we have to fight Apple constantly -- not o…

Apple doesn't make developers do anything. Developers write apps for their platform because it is the one where consumers want to spend their money. They do this by being mean to developers, or, rather, not allowing developers to be mean to customers. It's the same way that apple leans hard on their suppliers but at the end of the day it has led to creating a healthy and wealthy ecosystem that those developers and su…

> not allowing developers to be mean to customers.

apple has a history of denying apps for monopolistic reasons & collusion price fixing : https://apple.fandom.com/wiki/Criticism_of_Apple#Restriction...

> t's the same way that apple leans hard on their suppliers but at the end of the day it has led to creating a healthy and wealthy ecosystem

yes, like using child labour and working environments that require suicide nets: https://apple.fandom.com/wiki/Criticism_of_Apple#Student_and...

Re: Write code for the web

#228

Earlier quoted context omitted.

I just wish Web wasn't such a frustrating development experience. While it has improved leaps and bounds in the last decade, I still find it to be suboptimal when compared to native offerings. Most of that frustration comes down to tooling and more specifically TypeScript. I'm not sure how to succinctly express my pain here but I have found generally that I wrestle with the type system in TypeScript far more than nat…

That's because you're doing something much harder with web dev. You're making something that works almost everywhere. It's actually insane this is even possible. I bet one day, computronium will run Javascript.

Nah, the shitty parts of web dev are in basic building blocks other ecosystems handle without a problem. The fact that javascript can run anywhere doesn't mean it needs to have crappy build systems. It doesn't mean it needs to have constant breaking changes and flaky dependencies. CSS is crap for layouts. I've build apps with at least 10 layout systems, and CSS is the worst of all of them.

Re: Write code for the web

#229

Go ahead and write "code for the web" but be prepared to have to choose among a bunch of different JS libraries and CSS design systems depending on who the CTO is for your organization and who has their ear; writing bare-metal HTML/CSS and minimal Javascript won't get you far with the C-suite and you'll be pulling your hair out trying to get things to play nicely with each other (or wind up digging through five or te…

Echoing what others have said - Xcode is worse than all of that.

Re: Write code for the web

#230
post #119

Earlier quoted context omitted.

The analogy doesn't work. It's not like Apple provides their platform and then if you don't want to use it then fine, you're on your own. They are actively hostile towards you doing something else. If I leap off your analogy, which again doesn't really work, it's as if they throw tomatoes from their steakhouse as you go towards the pancake house.

Are they? They own the OS. And they reserve to themselves the rights to change how it behaves. There’s no standard API, only tooling. So yeah, it’s obvious that you’ll be in great pain if you try to sidestep the tooling. Everything apart from their SDK is and will always be an hack.

Are they what? Actively hostile? Yes, they are.

Of course they can do whatever they want. But it makes everyone slowly hate them.

Post reply on HN