Skip to content

fix(oxlint-plugin): accept intercepted dynamic route directories - #8

Merged
yordis merged 1 commit into
mainfrom
yordis/fix-intercepted-dynamic-routes
Oct 16, 2026
Merged

yordis merged 1 commit into
mainfrom
yordis/fix-intercepted-dynamic-routes

Conversation

@yordis

@yordis yordis commented Oct 16, 2026 •

Copy link
Copy Markdown
Member
  • Next.js lets intercepting routes target dynamic segments like (.)[username], so the directory naming rule should not force consumers to rename or suppress them.

View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
@cursor

cursor Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

PR Summary

Low Risk
Lint-only rule relaxation for valid Next.js App Router paths; no runtime or security impact.

Overview
trogonstack/require-kebab-case-directories now treats the suffix of Next.js intercepting route folder names as either kebab-case or a dynamic segment (e.g. (.)[username], (..)[...slug]), not only kebab names like (.)photo.

The rule logic is refactored with isRouteSegment / isDynamicSegment so intercepting prefixes reuse the same route-segment rules as plain dynamic folders. Docs note the intercepting + dynamic case. Unit and naming-preset tests add valid paths for those directories and broaden the list of accepted Next.js special files under the naming config.

Reviewed by Cursor Bugbot for commit 32beaee. Bugbot is set up for automated code reviews on this repo. Configure here.

@coderabbitai

coderabbitai Bot commented Oct 16, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 19 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 68317eeb-d155-4d36-a14b-d42bc518a8cd
📥 Commits

Reviewing files that changed from the base of the PR and between a46c89f and 32beaee.

📒 Files selected for processing: 4
  • packages/@trogonstack/oxlint-plugin/docs/rules/require-kebab-case-directories.md
  • packages/@trogonstack/oxlint-plugin/src/rules/require-kebab-case-directories.ts
  • packages/@trogonstack/oxlint-plugin/tests/node/configs/presets.test.ts
  • packages/@trogonstack/oxlint-plugin/tests/node/rules/require-kebab-case-directories.test.ts
  • 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.

@yordis
yordis merged commit c3ec576 into main Oct 16, 2026
6 checks passed
@yordis
yordis deleted the yordis/fix-intercepted-dynamic-routes branch October 17, 2026 04:03
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.

1 participant