Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Is there a way to run type checking ahead of time similat to typescript or python's mypy or pyright?


PHPStan is one of the more popular tools to evaluate that stuff. It works by examining each file and resolving all of the imports to verify that all of the types are compatible.

Jetbrains PHPStorm has this sort of type resolution built in (one of their value adds) but you can also run PHPStan instead of their proprietary version.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: