Beginning to wonder if there’s a place for compiler heroics in transforming React-style immediate-mode-with-diffing UI code into efficient retained mode code under the hood.
-
-
Despite initial hype around React, classic ‘90s retained mode UI really is the most resource-efficient way to write apps. But it’s not much fun to write compared to React. Best solution: Keep the developer ergonomics of React/etc. but compile to old-school UI code under the hood.
Show this threadThanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
I think Svelte.js tries to do this. Does feel like there's a lot of potential in that direction
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
There are a lot of libraries that do work this way. Example: https://lit-html.polymer-project.org/
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
SwiftUI encodes the tree structure in the return type of the rendering function so that only dynamic parts of the tree need to be diffed.
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
It wouldn't have to be very heroic if you had a strong model of the inputs to each element. Basically, isn't this a program design problem, more than an optimisation one?
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
iiuc
@glimmerjs works a lot like this? and more recently@sveltejs takes it a bit furtherThanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
I think Jetpack Compose do this
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.