dan’s alt Profile picture
Sep 13, 2020 7 tweets 2 min read Read on X
I wonder if our early messaging about Concurrent Mode should have been focused on mounts rather than updates. Some of the conversation I’m seeing assumes we could just “do less work” which is not an option for rendering *new* subscreens — where granular rerendering doesn’t help.
This depends on the app — some apps, like dataviz, almost exclusively do “updates”. So dataviz example, while effective visually, may have been a misdirection. In consumer apps a lot of the interactions we want to make smoother are mounts — like switching tabs or infinite scroll.
There’s also a question of responsibility. We consider what happens when you have hundreds of components that all run a little bit of code *our* responsibility. Userland code then dwarves library overhead in CPU time. We can’t just wash our hands and say “don’t write slow code”.
Granular rerendering is certainly useful (and disproportionally useful for dataviz and graphical editors). There are several ways you can solve it. The problem with many popular solutions is that they preclude solving the mounts. This is why we start from the other end.
There are many features that your library gets if you solve non-blocking mounts. Like pre-rendering the contents of a hidden tab optimistically without blocking the initial paint and delaying user input. Or rendering long lists in visually intentional chunks.
I don’t care if the library authors of today see this as a problem worth solving. But I want to inspire the authors of libraries of tomorrow to at least consider it. We have several tabs, each has a deep tree inside, each layer has a fixed user code cost. Now make it responsive.
Maybe this problem alone by itself isn’t worth your effort. It is hard. But if you spend enough time on it, you might discover that other areas — animations, data fetching, hydration, code splitting — now allow new solutions you couldn’t consider before. If your model allows it.

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with dan’s alt

dan’s alt Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @dan_abramov

Jul 20, 2023
i feel bittersweet sharing i’m leaving my job at meta in a few weeks. working in the react org at meta has been an honor. i am thankful to my past and present colleagues for taking me in, letting me make mistakes, helping me see my strengths, being kind, and sharing their time.
for the past three years, i kept saying i’d leave “in a year or so” but the moment never felt right. i wanted to (1) finish the new docs and (2) see a broadly usable Suspense data fetching integration shipping. after years of work from the team, both have shipped this spring.
i felt hesitant leaving earlier because not too long ago, leaving meta used to mean leaving the react team. that would feel too sad for me. but it is not true anymore. react has become a multi-company project, and there are several independent engineers on the team too.
Read 15 tweets
Jun 7, 2023
fwiw i expected the article to be clickbait (and the title is) but it’s actually pretty balanced. imo it gets a few things wrong so i’ll provide an alternative perspective (tiny thread)
the framing of “existing features like useState / react-query / CSS-in-JS don’t work” is misleading at best.

to understand why, consider that here is the React you already know… A circle saying React Tree ...
… in the RSC paradigm, all of these things keep working! we are not *replacing* that layer — we are adding a *new* layer that can run at the build or request time. that’s Server Components. the only thing they can do is pass data to the “React you already know”… Same picture as before, but...
Read 9 tweets
Jun 6, 2023
yeah i thought this was nice. idk if “spatial computing” will catch on or will stay as an apple-esque “we’re too good to use the industry terms” thing, but i thought it’s funny that this launch simultaneously validated meta’s bet *and* made meta’s branding feel instantly obsolete
mark’s meta announcement felt corny because they had to come up with a vision of mainstream aesthetics for a medium that has no mainstream community yet. of course it’s not believable! apple stuck with floating 2d stuff in the presentation because it feels familiar.
i think this is great news for meta too. i imagine it will be easier to motivate sweating the details and making them cohesive after apple resets the expectations of what this medium is supposed to feel like.
Read 6 tweets
Jun 5, 2023
lol sorry but i think apple did it again
curious what the actual apple vision (not pro) looks like
vision is such a dope name for a product. focuses it on the human (what function does it serve you) rather than on the place you’re supposedly in (whatever reality). “apple vision” also kinda says “this is *the* thing we’re working on”
Read 7 tweets
May 19, 2023
i mean i sorta get the point but also if a ballpen wrote stuff by itself and contained much of humanity’s collective knowledge within, maybe people would have a point being a bit more concerned about ballpens too? it’s more like a phone line with an alien made out of our voices
which is maybe fine, who knows! the internet is pretty good imo and it sure sounds a lot more dangerous than a ballpen. but like idk it’s just such a freaky vibes piece of technology, both natural and freaky like golems or acid. you don’t see language itself reanimated every day.
the closest positive emotional reference i can think of is something like talking to ancestor spirits. and even those stories typically have preexisting oracles instead of groups of people competing to discover and create them. it’s freaky
Read 4 tweets
Apr 20, 2023
real talk. modern frameworks like Next.js and Gatsby have sort of an “SPA mode”. the main difference is with classical SPAs is that they produce several entry HTML files (per route). this means a purely static (not Node!) deploy needs a tiny URL -> path config. this trips people.
we need to get past this hurdle collectively. it is ridiculous if this is the reason we’re delaying adoption of better tools. SPAs with multiple HTML entry files are much better SPAs! we just need some standard way to deploy these across providers.
ideas welcome. i know there are scripts that generate config eg for nginx and apache. cool. i also know some providers infer these paths by default for next and gatsby. also cool. but can we have one obvious way to do it across the ecosystem? so that every single shop knows how.
Read 4 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us!

:(