Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 18 additions & 8 deletions biome.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,28 @@
"ignoreUnknown": false,
"includes": [
"**",
"!node_modules",
"!vendor",
"!composer.json",
"!composer.lock",
"!package.json",
"!package-lock.json",
"!**/analytics.*",
"!**/metrics.*",
"!.agents",
"!.ai",
"!.ai-factory",
"!.claude",
"!.codex",
"!.cursor",
"!.gemini",
"!.github",
"!.junie",
"!.mcp.json",
"!build",
"!composer.json",
"!composer.lock",
"!coverage",
"!dist",
"!build",
"!public"
"!node_modules",
"!package-lock.json",
"!package.json",
"!public",
"!vendor"
]
},
"formatter": {
Expand Down
4 changes: 1 addition & 3 deletions presets/rector/default.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,7 @@
typeDeclarations: true,
)
->withPhpSets()
->withImportNames(
removeUnusedImports: true,
)
->withImportNames()

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve unused-import removal for supported Rector versions

This drops removeUnusedImports: true even though this package reaches Rector via driftingly/rector-laravel, whose supported range still allows rector/rector:^2.2.7; Rector only made unused-import removal the default in 2.5 (the release notes say “Removing unused imports by default”). In projects with a lockfile or constraint keeping Rector 2.2–2.4, publishing this preset now stops removing unused use statements (the same regression is present in laravel.php), so keep the explicit flag or raise the minimum Rector version.

Useful? React with 👍 / 👎.

->withComposerBased(
phpunit: true
)
Expand Down
4 changes: 1 addition & 3 deletions presets/rector/laravel.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,7 @@
)
->withPhpSets()
->withSetProviders(LaravelSetProvider::class)
->withImportNames(
removeUnusedImports: true,
)
->withImportNames()
->withComposerBased(
phpunit: true,
laravel: true
Expand Down