I was looking for the docs on how to use defaultProps and found the PropTypes docs. The first thing I saw there was the yellow box at the top that says:
Note:
React.PropTypes has moved into a different package since React v15.5. Please use the prop-types library instead.
I read this as meaning "this page is out of date, please see those docs", especially because the yellow box looks so important, and went to that package, which has much less comprehensive documentation. (Including no mention of defaultProps currently, although that's going to be fixed.) I didn't understand until re-reading it the next day that it was intended for people using PropTypes under its old name and I was supposed to carry on reading the page.
I suspect that I may not be the only learner prone to this kind of misreading, so may I please suggest that you move the note to a little further down the page and possibly tweak the wording? Thank you.
I was looking for the docs on how to use
defaultPropsand found the PropTypes docs. The first thing I saw there was the yellow box at the top that says:I read this as meaning "this page is out of date, please see those docs", especially because the yellow box looks so important, and went to that package, which has much less comprehensive documentation. (Including no mention of
defaultPropscurrently, although that's going to be fixed.) I didn't understand until re-reading it the next day that it was intended for people using PropTypes under its old name and I was supposed to carry on reading the page.I suspect that I may not be the only learner prone to this kind of misreading, so may I please suggest that you move the note to a little further down the page and possibly tweak the wording? Thank you.