Caching in Next.js 13

preview_player
Показать описание
How to cache fetch requests and RSC payload.
How to revalidate cached data with revalidateTag.

Music:
Рекомендации по теме
Комментарии
Автор

Really appreciate it! Keep em going! Would be really nice to see a tutorial of a full next project from your POV

jacobforsbergg
Автор

I had to go through 10 dogshit videos before I found yours 😭

ty ty so much

braiNN
Автор

That’s cool. I’d like to see how it works with SWR

morrisalanisette
Автор

Thank You.

1 question.

lets say i have 2 scenarios -
i am fetching a collection of Posts.
i am fetching 1 Post by slug.

is it good practice to tag them both with ["posts"]

like-
approach 1
fetch("url/posts", { tags: ["posts"] })
fetch("url/post/slug", { tags: ["posts"] })


approach 2
fetch("url/posts", { tags: ["posts"] })
fetch("url/post/slug", { tags: ["post-slug"] })

subhranshudas