nextjs-pathname-id-fetch
Installation
SKILL.md
Next.js: Pathname ID Fetch Pattern
When This Pattern Applies
Use this pattern whenever a page needs to load data based on whatever identifier appears in the URL. Common scenarios include:
- Detail pages for products, posts, or users (
/products/{id},/blog/{slug}) - Admin dashboards that drill into a selected resource (
/admin/orders/{orderId}) - Documentation or knowledge bases with nested paths (
/docs/getting-started/installation)
If the requirement says the data should change depending on the current URL path, the route segment must be dynamic (e.g., [id], [slug], [...slug]).