by maxharris · 6y ago · 0 comments
I got pretty far! But I gave up working on it when I realized that I was going to be pushing this boulder uphill for years.
So what changed? I picked up Swift and SwiftUI, and it turns out that some of the ideas that I had were the same ones the SwiftUI folks went with!
For all the web has given us, I think its APIs are holding us back now. I still think we need something open and decentralized that competes with the App store and Play store, but one that offers apps that use basically the same APIs and technology that the native apps use.
Last thing: I know Apple cripples browsers on their platforms. I've run into all those issues personally in my work! That still doesn't make the web the right thing. Here's James Mickens telling us how to fix the browser's busted architecture: https://www.youtube.com/watch?v=1uflg7LDmzI
I can put a div in a div, border-radius=50%, position=relative,absolute, add a single event handler and that's a digital joystick. Run a local single-exe websocketify and you can control anything from a CNC router to an army of drones.
I dislike Electron* as much as the next guy and steer clear of npm like my life depends on it, but there's no single thing that's more universal and easy to hack on than a simple HTML file.
Are you implying that this is somehow unique to the web or HTML? Because I can assure you that it is not.
We've got a handful of basic form inputs, incredibly inflexible tables, and some semantic rectangles. That's basically it.
Even the form inputs can be a pain. It's insane to me that the only way to change the background colour of a checkbox is to hide it and build your own with CSS hacks (pseudo-elements etc.).
I guess the fact that any element needs to function purely from markup without any code severely hampers them, but I can't believe how much time we're all wasting having to build things as basic as pop-out menus by hand.
I will die on this hill. HTML is not a UI toolkit or an SDK. It is a user-facing interface.
I know it gets presented as a toolkit, I know that on some level it overlaps with a toolkit/layout language. But the most important thing HTML does is it provides a plain-text user-facing interface for an app.
Complaints like this are kind of like arguing that the terminal is a bad layout tool. I guess? But many of the things that would make the terminal into a better layout tool would get in the way of forcing developers to provide a pure-text interface for their apps.
In the same way, many of the features people want to pull into HTML (data-bindings for tables, content reflow between arbitrary elements, arguably a lot of the custom element/template work that Google is doing) are kind of counterproductive once you start looking at HTML as an interface instead of as a programming tool.
It’s not fit for the purpose of building applications. I strongly support the idea of an alternative.
Take a look at Flutter(which is similar to swiftUI). I know Google is behind it but it's so damn good. The JS community spends so much time creating new tools on top of older tools to achieve simple things that should be trivial in 2020. Meanwhile, flutter is typescript+react+webpack+component library + a bunch of npm dependencies(because dart has a proper standard library) + advanced styling/layout and animation primitives inside the programming language + amazing IDE support + compiler that generates optimized AOT native code.
Flutter Web is a huge bet though because it completely throws away every web tech and builds UIs on top of <canvas>. That way you get the same API's you get on mobiles. The results are not good right now but alongside Microsoft's Blazor they are the only technologies competing with the broken web landscape.