@nextjs Benefits of fine-tuning over prompt engineering:
◆ Token savings (no need to have a massive prompt)
◆ Faster response times (ditto smaller prompt)
◆ Better quality results (tailored to the exact behavior you want)
I spent the weekend upgrading dub.sh to @nextjs App Router.
Featuring:
◆ Segment-level caching
◆ Server components
◆ Parallel & intercepting routes
◆ Dynamic OG images + Metadata API
Here's what I learned 🧵
1. You can now cache individual fetch calls via segment-level caching.
Combine static, dynamic, and revalidated data inside reusable components. E.g. on @dubdotsh's homepage:
◆ GitHub star count: 60s
◆ Tweet testimonials: 1hr
The best part? Detailed logs for each cache hit 😍
2. Server components help you write less code.
No more bulk fetching data inside getStaticProps and prop drilling all the way down to your child component – just use a server components instead.
Here's the (much cleaner) index page after the migration: