4 ms·
In case OP or anyone else is interested: PHP lacks strict typing (by default). For older applications I agree with you, but in the last few versions it's been a
by TheCapeGreek 6y ago
In case OP or anyone else is interested: PHP lacks strict typing (by default). For older applications I agree with you, but in the last few versions it's been a lot better. Depending on your framework or tools, you can customise file templates and add strict typing to each file, i.e. Laravel's `php artisan make:xxx` can now always have declare(strict_types=1); . Of course you can't assume that for external packages, but it's highly recommended.