When you create reusable React components, you want to make sure that people use them correctly. The best way to do this is to use TypeScript in your codebase to give you compile-time checking of your code. But if you’re not using TypeScript, you can still use PropTypes to get runtime validation. Between you and me, when I was still doing AngularJS work, I was so envious of this feature, that I tried to build it into AngularJS.
In this lesson we’ll learn how PropTypes work, why they’re not enabled in production, and how to use the pre-built prop-types package from the React team.
Officially it seems that PropTypes are not recommended ? With flow or typescript instead recommended.
For larger code bases
I think TS and Flow are great but it adds a whole other layer of complexity so it's nice to have an option the check props without all that config.