Nexus CS Config v3.3.0
Added 🔥
- Support for custom fixers is added. This release contains two new fixers,
SpaceAfterCommentStartFixer
andNoCodeSeparatorCommentFixer
- Added
FixerGenerator
to easily register all custom fixers in directory
To use the custom fixers in your ruleset, you just need two (2) steps:
- In the
$options
array, add the keycustomFixers
with the valueFixerGenerator::create('path/to/fixers', 'namespace')
. - In the same array, add the key
customRules
with value of array of desired rules.
For example:
$options = [
'finder' => $finder,
+ 'customFixers' => FixerGenerator::create('src/Fixer', 'Nexus\\CsConfig\\Fixer'),
+ 'customRules' => [
+ \Nexus\CsConfig\Fixer\Comment\SpaceAfterCommentStartFixer::name() => true,
+ \Nexus\CsConfig\Fixer\Comment\NoCodeSeparatorCommentFixer::name() => true,
+ ],
];
Stay tuned for more custom fixers in future releases.
Changed ⚙️
- Bump
friendsofphp/php-cs-fixer
version to v3.1.0 River to use latest fixers
Please refer to the CHANGELOG for the detailed list of changes.