Skip to content

Conversation

@DanielSinclair
Copy link
Collaborator

@DanielSinclair DanielSinclair commented Dec 7, 2025

TL;DR

Added TypeScript route type definitions to all Next.js projects.

What changed?

Added a reference path to ./.next/types/routes.d.ts in the next-env.d.ts file across all Next.js examples and packages. This change enables TypeScript to recognize and provide type checking for Next.js route definitions.

How to test?

  1. Run npm run dev or yarn dev in any of the affected Next.js projects
  2. Verify that TypeScript correctly recognizes route paths in the codebase
  3. Check that route-related autocompletion works in your IDE

Why make this change?

This change improves the developer experience by providing better TypeScript support for Next.js routes. With these type definitions, developers will get autocompletion and type checking for route paths, reducing errors and improving code quality. This is a recommended practice for Next.js projects using TypeScript.

@changeset-bot
Copy link

changeset-bot bot commented Dec 7, 2025

⚠️ No Changeset found

Latest commit: 6b5f93f

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel
Copy link

vercel bot commented Dec 7, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
rainbowkit-example Ready Ready Preview Comment Dec 7, 2025 8:14am
rainbowkit-site Ready Ready Preview Comment Dec 7, 2025 8:14am

@DanielSinclair
Copy link
Collaborator Author

@DanielSinclair DanielSinclair changed the title fix: next js route types chore: next js route types Dec 7, 2025
@DanielSinclair DanielSinclair marked this pull request as ready for review December 7, 2025 08:11
@DanielSinclair DanielSinclair requested a review from a team as a code owner December 7, 2025 08:11
@DanielSinclair DanielSinclair merged commit 37c87eb into main Dec 7, 2025
6 of 8 checks passed
@DanielSinclair DanielSinclair deleted the daniel/next-route-types branch December 7, 2025 08:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants