Use PHP 7.4 featers and PHP 8 polyfills
This commit is contained in:
26
rector.php
26
rector.php
@ -0,0 +1,26 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
use Rector\Config\RectorConfig;
|
||||
use Rector\TypeDeclaration\Rector\ClassMethod\AddVoidReturnTypeWhereNoReturnRector;
|
||||
return RectorConfig::configure()
|
||||
->withPaths(
|
||||
[
|
||||
__DIR__ . '/inc',
|
||||
__DIR__ . '/views',
|
||||
]
|
||||
)
|
||||
->withAutoloadPaths(
|
||||
[
|
||||
__DIR__ . '/vendor/squizlabs/php_codesniffer/autoload.php',
|
||||
__DIR__ . '/vendor/php-stubs/wordpress-stubs/wordpress-stubs.php',
|
||||
]
|
||||
)
|
||||
->withSkipPath(__DIR__ . '/vendor',)
|
||||
->withImportNames(false)
|
||||
->withPhpSets()
|
||||
->withRules(
|
||||
[
|
||||
AddVoidReturnTypeWhereNoReturnRector::class,
|
||||
]
|
||||
);
|
||||
|
Reference in New Issue
Block a user