dadadev / phpstan-symfony-routing
A phpstan plugin to analyze generating of routes from symfony routing
Installs: 6 278
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 1
Forks: 2
Open Issues: 0
Type:phpstan-extension
Requires
- php: ^8.1
- phpstan/phpstan: ^2.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.0
- php-parallel-lint/php-parallel-lint: ^1.2
- phpstan/phpstan-phpunit: ^2.0
- phpstan/phpstan-strict-rules: ^2.0
- phpunit/phpunit: ^9.5
- symfony/framework-bundle: ^6.4 || ^7.0
- symfony/polyfill-php80: ^1.24
- symfony/routing: ^6.4 || ^7.0
Conflicts
- symfony/framework-bundle: <3.0
This package is auto-updated.
Last update: 2025-01-13 13:11:51 UTC
README
This extension provides following features:
- Notifies you when you try to generate a URL for a non-existing route name.
Installation
To use this extension, require it in Composer:
composer require --dev dadadev/phpstan-symfony-routing
If you also install phpstan/extension-installer then you're all set!
Manual installation
If you don't want to use phpstan/extension-installer
, include extension.neon in your project's PHPStan config:
includes:
- vendor/dadadev/phpstan-symfony-routing/extension.neon
To perform framework-specific checks, include also this file:
includes:
- vendor/dadadev/phpstan-symfony-routing/rules.neon
Analysis of generating URLs
You have to provide a path to url_generating_routes.php
for the url generating analysis to work.
parameters: dadadev: urlGeneratingRulesFile: var/cache/dev/url_generating_routes.php