4 ms·
Unless you don't use the DOM at all for UI for web apps: https://news.ycombinator.com/item?id=34612696 https://news.ycombinator.com/item?id=34612696 It would e
by satvikpendem 3y ago
Unless you don't use the DOM at all for UI for web apps: https://news.ycombinator.com/item?id=34612696 https://news.ycombinator.com/item?id=34612696
It would enable any language to simply render their own UI and handle things like accessibility with their own accessibility based DOM that just handles the accessibility parts rather than the entire logic of the app. I believe this is what Flutter does.
- pavlov 3y agoThis means shipping an entire UI framework as part of the web app onto a computer that already is running multiple UI frameworks. For example on macOS with Chrome, you’ll have Flutter running on Chromium running on AppKit. All of these provide text layout engines, compositors, 2D and 3D graphics, widget hierarchies, scripting languages… Hundreds of megabytes of redundant stuff loaded in memory to run some typically basic Flutter app. I know, we can’t magically have native binaries delivered on the web (that was ActiveX and it was bad). But it somehow boggles the mind that this is what we ended up with.
- satvikpendem 3y agoWell, people like web apps but not desktop apps, but then also complain that web apps are slow (see Electron), so what can we do otherwise?
- troupo 3y ago> simply render their own UI simply is doing a lot of heavy lifting here. > and handle things like accessibility with their own accessibility based DOM that just handles the accessibility just is doing as much heavy lifting as simply before it. > I believe this is what Flutter does. Flutter "just" "simply" have a trillion-dollar company sponsoring their project that came out of internal power struggles. And they have "just" "simply" been working on it for 6 years, and currently has 11 thousand issues in their repository.
- satvikpendem 3y agoWell, that's why I use Flutter rather than some other community-led project in another language, like I see in Rust like Slint, because it's quite a big task to redo a lot of this work for WASM.
- troupo 3y agoYes, see how "simply" and "just" quickly became "I will only use code from a trillian-dollar corporation because it's neither 'simple' nor 'just' to build a proper UI framework"
- satvikpendem 3y agoSure, maybe I shouldn't have used those words, but my point was that it will enable a lot more flexibility for people who want to write apps across platforms and with their own preferred language instead of Javascript, because it will all compile down to WASM, as well as stopping people from bemoaning the slowness of Electron, or shipping an entire browser per app. Instead, one ships the app to the browser.
- troupo 3y ago> or shipping an entire browser per app. Instead, one ships the app to the browser. Yes. Instead you're shipping the entire app, including the whole graphical framework, with every app. To quote Figma, "Pulling this off was really hard; we’ve basically ended up building a browser inside a browser." https://www.figma.com/blog/building-a-professional-design-tool-on-the-web/ https://www.figma.com/blog/building-a-professional-design-to... Are you sure this is what you want?
- satvikpendem 3y agoIt makes writing the desktop apps easier, instead of using a separate framework for the web and another one for the desktop (which costs engineering time and money), or, again, shipping an entire browser per app (which saves engineering time and money but is a bad experience for the end user). You can't escape this complexity, there's no way around it if you want to make cross platform apps. Now if you just want to make a website or webapp (with no intention of making it cross platform), stick with the DOM, it's not going anywhere.
- rapnie 3y agoIt is what Makepad is working on in an interesting way using Wasm and Rust. They have created a Figma-like DSL and a good code separation with the logic behind it. You can edit UI's of in-production apps, and they are bundling an editor for that. Accessibility is an issue, and the project are looking to offer proper support there. In their video linked on the README they run the conference slides on Makepad with live apps embedded and running at 120 fps. https://github.com/makepad/makepad https://github.com/makepad/makepad https://news.ycombinator.com/item?id=36567681 https://news.ycombinator.com/item?id=36567681
- jeroenhd 3y agoI swear to god, if shipping an entire renderer with every web page or all becomes the norm I will just ship WINE and a win32 executable instead of writing normal web pages. If we're going to move to bloated renders everywhere I may as well use write my code for the de facto standard cross-platform native application API.
- satvikpendem 3y agoAs well you can, in fact I've seen something like that already where WINE was compiled to WASM: https://www.wasm.builders/dustinbrett/webassembly-in-my-browser-desktop-environment-3alc https://www.wasm.builders/dustinbrett/webassembly-in-my-brow...