Content Deep Dive
Shallow Routing in Next.js
Blog post from Netlify
Post Details
Company
Date Published
Author
Cassidy Williams
Word Count
239
Company Posts That Month
Language
English
Hacker News Points
-
Summary
Shallow routing in Next.js allows for changing website URLs without re-running data fetching methods again, making it useful for adding query strings or routes that change based on user behavior. To use shallow routing, the `useRouter` hook is used with `{ shallow: true }` added to router push commands. This technique can be applied manually by developers to improve performance and reduce database queries in their applications.
Trends Found in this Post
No tracked trend matches for this post yet.