5 ms·
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 w
by rubicon33 3y ago
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 native offerings.
- CharlieDigital 3y ago> I just wish Web wasn't such a frustrating development experience It's got to be better than building to target two totally different platforms (and even more once you factor in tablets, Windows desktop/Linux/macOS) and then jumping through hoops to get your app packaged, reviewed, and updated consistently onto the target devices. > Most of that frustration comes down to tooling and more specifically TypeScript I think that a lot of folks get frustrated with TS because they are coming at it from the wrong perspective. Instead of thinking about it like a static type system, think about it like "JavaScript with shape definitions". Give this a shot: https://chrlschn.dev/blog/2023/09/typescript-is-not-a-programming-language/ https://chrlschn.dev/blog/2023/09/typescript-is-not-a-progra...
- threeseed 3y agoThere are plenty of options e.g. React Native, Flutter if you want one codebase. And if you want to have a lowest common denominator user experience that's fine but you shouldn't expect users to reward you for it. That's why successful apps tailor the experience for each platform.
- CharlieDigital 3y agoNeither solution takes away the fact that you have to jump through hoops for distribution. Web apps and PWA's built with HTML and JavaScript are likely to work as-is for a decade or more given we are likely to see minimal incompatibilities with existing HTML, JavaScript, and CSS in that time and likely to see more net new capabilities. > if you want to have a lowest common denominator user experience... One is a native app with a budget in the millions built by dozens of engineers. One is a web app built by...me: https://youtube.com/shorts/bxs9ZpIJ6RM https://youtube.com/shorts/bxs9ZpIJ6RM Not sure that there's that much sacrifice when it comes to modern web apps.
- FredPret 3y agoThat'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.
- yCombLinks 3y agoNah, 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.
- FredPret 3y agoCorrect, but HTML + JS + CSS is the standard we seem to have settled on, and having a globally accepted standard for anything is a unique and historic achievement, let alone for free, fast, and robust global distribution of Turing-complete computation and content delivery. Now we can hope that those building blocks improve over time, but the current situation is so much better than it could have been.
- mnvrth 3y agoThis is beautifully put! I hope more people are able to understand the point you're making, especially how "having a globally accepted standard for anything is a unique and historic achievement".
- FredPret 3y agoThank you! I guess I can make myself more clear - the good thing about CSS is not the way it does layouts, but that it can do layouts on almost any device. You can come up with a better system that runs on your own machine (1 unit of effort), but then you have to convince everyone and their dog to adopt your new standard (1 billion units of effort).
- continuational 3y agoThe TypeScript type system is obscenely complicated because it has to be able to type almost any weird pattern people used when there was no type system. Most dynamically typed languages are adding type systems right now, and they all face the choice between rewriting/wrapping the whole ecosystem or build a very complex and ultimately unergonomic type system.
- jwells89 3y agoIt’s too bad that Swift → JS compiler projects are all stalled. Swift syntax is similar and I think it’d be a nice step up for people who don’t care for compatibility with legacy JS and want uncompromised static typing on the web.
- ahmedfromtunis 3y agoI enjoy building for the web using "native" tooling, writing CSS and JavaScript "by hand." Years ago I tried to up my game and learn to use grunt and babble and other build tools. However, I found the process extremely complex, only to end up with finicky systems that made me even more stressful, not less. I decided to ditch all that PoS and do things the easy (and logical) way. Never looked back.
- noduerme 3y agoI 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.
- sodapopcan 3y agoKeep your business logic on the server and use whatever language you want. I stick to vanilla JS and only use it for DOM manipulations. I try and leverage CSS for simple manipulations when I can. I don't go out of my way to, but it can do a lot these days.
- aabbcc1241 3y agoKeeping this mindset, I encourage you try liveview in any language of your choice [1]. This approach allows you to handle business logics on the server, and update the screen in browser from the server as well. [1] https://github.com/liveviews/liveviews https://github.com/liveviews/liveviews
- sodapopcan 3y agoHa, I’ve been a Phoenix LiveView zealot from almost day one, thank you much ;) <3
- jitl 3y agoI stopped wanting to write SwiftUI because the compiler there is the worst I’ve ever used. It uses some kinds of complicated inference for ViewBuilders, and the inference can get confused if you have a type error and deadlock checking a View. It’ll put an error squiggle on an entire function and say “sorry we timed out trying to typecheck this, can you figure it out?” I’ve never used any typed language compiler that gives up on 100 line or less functions.
- ciconia 3y ago> I just wish Web wasn't such a frustrating development experience. I have to say, having recently gone back to doing some web dev work (doing some dashboards with lots of D3 visualisations), I was pleasantly surprised to see how better things have gotten. working with CSS is better (with stuff like grid, flex, nested selectors), and JS is also much much better (import maps, fetch API). I'd say for developing cross-platform apps it's a pretty good deal.
- mardifoufs 3y agoDeveloping in native GUI frameworks is just as frustrating. Using QT for complex GUIs is more frustrating than HTML5/react or whatever