fix: attempting to fix style, user guide, and other small errors

This commit is contained in:
Lonnie Ezell 2023-05-22 22:44:12 -05:00
parent d2c8e455ee
commit c6b6341207
No known key found for this signature in database
GPG Key ID: 71836D6EF250F1D1
5 changed files with 14 additions and 4 deletions

View File

@ -4,6 +4,7 @@ namespace Config;
use CodeIgniter\Events\Events;
use CodeIgniter\Exceptions\FrameworkException;
use CodeIgniter\HotReloader\HotReloader;
/*
* --------------------------------------------------------------------
@ -46,8 +47,8 @@ Events::on('pre_system', static function () {
Services::toolbar()->respond();
// Hot Reload route - for framework use on the hot reloader.
if (ENVIRONMENT === 'development') {
Services::routes()->get('__hot-reload', function() {
(new \CodeIgniter\HotReloader\HotReloader())->run();
Services::routes()->get('__hot-reload', static function() {
(new HotReloader())->run();
});
}
}

View File

@ -113,6 +113,6 @@ class Toolbar extends BaseConfig
* used to determine if the hot-reload feature should reload the page or not.
*/
public array $watchedExtensions = [
'php', 'css', 'js', 'html', 'svg', 'json', 'env'
'php', 'css', 'js', 'html', 'svg', 'json', 'env',
];
}

View File

@ -7,6 +7,9 @@ use FilesystemIterator;
use RecursiveDirectoryIterator;
use RecursiveIteratorIterator;
/**
* @internal
*/
class DirectoryHasher
{
/**

View File

@ -2,6 +2,9 @@
namespace CodeIgniter\HotReloader;
/**
* @internal
*/
class HotReloader
{
public function run()

View File

@ -5,7 +5,10 @@ namespace CodeIgniter\HotReloader;
use RecursiveFilterIterator;
use RecursiveIterator;
class IteratorFilter extends RecursiveFilterIterator
/**
* @internal
*/
class IteratorFilter extends RecursiveFilterIterator implements RecursiveIterator
{
private array $watchedExtensions = [];