4 ms·
I wish Google would develop protocols instead of frameworks, and only then put Dart (and others) on top. This way people would be able to choose their language
by k_bx 7y ago
I wish Google would develop protocols instead of frameworks, and only then put Dart (and others) on top. This way people would be able to choose their language on top, e.g. I'd love to use Elm, for one. No runtime errors, no mutability, opinionated built-in FRPish architecture. Dart has none of that.
- skybrian 7y agoThat's quite a tall order since any general-purpose UI framework is going to have a huge API surface area. But Elm runs in a browser, so it should work fine on Chromebooks. I guess you could use the Linux container for Elm development, but I don't know what the rough edges are for doing web development that way.
- k_bx 7y agoWell, HTML is one example of general-purpose UI framework that's separate from JavaScript in a way that lets you replace JS with something else. Why can't something similar be done for Flutter components? There's an example of elm-bootstrap library, where bootstrap components were reused, but Elm logic was added on top instead of JS one. Why wouldn't refactoring Flutter into Flutter-core similarly work? Also, I didn't understand your comment about the container and how it's related to this.
- skybrian 7y agoThe HTML DOM API is in no way separate from JavaScript. It's a mutable API that's tied into the JavaScript garbage collector, uses inheritance (unlike some languages) and uses JavaScript values in method parameters and return values. The only way to access it (once a web page is loaded) is through JavaScript. To interact with it from another language, you need at least an adapter layer that does foreign function calls to JavaScript, or you need to compile the entire language to JavaScript like Elm does. Elm works because Elm is specifically designed to compile to JavaScript and they put a lot of effort into making it smooth. (And bootstrap is part of the same JavaScript ecosystem.) In theory you could do the same thing for Flutter by compiling some other language to Dart. It seems unlikely anyone would make the effort any time soon, though. Regarding the Linux container, it's not directly related; I was just pointing out how someone might do Elm development on a Chromebook.