Skip to content

feat(prerender): support rou3 patterns in prerender.ignore - #4961

Merged
pi0 merged 1 commit into
mainfrom
feat/prerender-ignore-patterns
Oct 29, 2026
Merged

pi0 merged 1 commit into
mainfrom
feat/prerender-ignore-patterns

Conversation

@pi0x

@pi0x pi0x commented Oct 29, 2026

Copy link
Copy Markdown
Contributor

Strings in prerender.ignore can now be rou3 route patterns, such as /blog/** or /users/:id. This resolves the TODO: support rou3 patterns in matchesIgnorePattern.

  • A string with * or : is matched as a rou3 pattern (via routeToRegExp, cached per pattern) against the path without its query string.
  • A string without those characters is still matched as a prefix, exactly as before, so existing configs keep working.
  • RegExp and function entries are unchanged.

In rou3 1.0, * and ** both match across segments (/blog/* also ignores /blog/a/b), and both match the base path itself (/blog). :name matches one segment. The docs say this directly.

Unit tests cover prefix strings, **, *, :param, query strings, RegExp and functions. The docs and JSDoc are updated.

🤖 Generated with AI assistant

@pi0x
pi0x requested a review from pi0 as a code owner October 29, 2026 11:19
@vercel

vercel Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

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

Project Deployment Actions Updated
nitro.build Ready Ready Preview Oct 29, 2026 11:20am UTC

Request Review

@coderabbitai

coderabbitai Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Caution

Review failed

The pull request is closed.

Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@pkg-pr-new

pkg-pr-new Bot commented Oct 29, 2026

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/nitro@4961

commit: 55d4872

@pi0
pi0 merged commit ab10877 into main Oct 29, 2026
15 of 16 checks passed
@pi0
pi0 deleted the feat/prerender-ignore-patterns branch October 29, 2026 11:21

This branch was successfully deployed

1 active deployment
Preview — 55d48724 Deployed Oct 29, 2026 by vercel[bot]
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