Looks sleek! Maybe super helpful for education imo
Posts by Alex Sidorenko
P.S. router.refresh does not invalidate cached data (on the server), revalidatePath does
revalidatePage/Tag in server action updates data in one round trip, so a good default for mutations
router.refresh is for non-mutation cases (refresh data on client event, etc...)
On the bright side, it's easier to learn peripheral stuff from first principles without cookie banners or worrying about asking stupid questions
Easier to broaden the scope, harder to hyper-specialize
The first point is the main one, I think. Comes from folks who work in companies with clear backend/frontend divide. They don't want RSC because for them, it's more hustle for no benefit.
So the pushback (at least in part) comes from the existing structures of work we adapted during SPA era
Got you. From my observation, most folks who miss SPA behavior from Next mainly want two things:
1. Static output with no node server
2. Instant route navigation
But if you only disable SSR/SSG but not RSC (keep rendering RSC to json payload during doc request), wouldn't this still block navigation (so not really SPA)? Or do you mean only keeping RSC for server actions?
It could just be about attention allocation. I can listen to someone speaking for 30 minutes while making breakfast. Not possible with written articles
Also, I haven't detected that influence in Dune to be honest π At least not in the movies
I heard that Frank Herbert was influenced by Alan Watts (taoism/zen buddhism) when writing Dune. Not sure if it was the primary trigger for writing it, though
Yep, and RSC makes "invalidate everything" much cheaper. And yet, there are still cases when client-side cache is a must (e.g. dashboard with cards => revalidate one card without revalidating others)
It would be great if RSC covered this use case
bsky.app/profile/alex...
Even then, you may have a dashboard with multiple cards and want to revalidate each card separately without revalidating all the others.
Nothing is blown away in terms of client state persisting, but revalidateTag/revalidatePath re-renders entire RSC tree from the root including layouts (and refetches everything in them). Ideally, there should be a way to revalidate the page segment separately (similar to navigation)
React started componentization of web dev
React Server Components continues it
Next is working on some sort of selective revalidation.
But yea, even something like "revalidateSegmentPage" could help, as right now it's only revalidatePath/revalidateTag, which both re-render the entire RSC tree from the root, including all layouts
Yep, that's the missing bit in existing implementations rn
bsky.app/profile/alex...
But I feel like it's nuanced, as RSC makes "blowing away your entire page" a viable option in many cases.
Anyway, it would be awesome if you could clarify how RSC compares/integrates with existing client-side data fetching libs in your write.
One thing that I noticed is that people just habitually default to Tanstack Query for data fetching when using React. And in this case, RSC sorta stays in the way instead of helping.
On which Tanner pointed out (rightly so, imo) that you still need selective revalidation from the client.
Ryan is the π of talks
Reddit is being Reddit π
Anonymous (no reputational damage) = more unfiltered, honest feedback, but allows arguing while being wrong
P.S. "Youβre right that such leaves could in principle be HTML-only"
Oh, this is very interesting π
Is this optimization planned?
"Vercel AI SDK - how do I get ai to interpret the tools response?"
π
Is selective revalidation conceptually possible with RSC? Say, I have a dashboard with 4 charts (each is a separate server component), and I want to revalidate only the 2nd one without re-rendering the entire page on the server.
What was your previous metaphysics?
Anyone lives in Ericeira, Portugal? How do you like it?
π
Caching Prisma queries with dynamicIO in Next.js
Yep, makes sense
30 fps π’
Composable caching in Next.js with dynamicIO
Delba's videos are sick