Merge pull request #1370 from hanzhijue/patch-1

Fix the example of "propTypes"
This commit is contained in:
Joe Lencioni
2017-04-12 07:17:10 -07:00
committed by GitHub

View File

@@ -360,8 +360,8 @@
};
// good
function SFC({ foo, bar }) {
return <div>{foo}{bar}</div>;
function SFC({ foo, bar, children }) {
return <div>{foo}{bar}{children}</div>;
}
SFC.propTypes = {
foo: PropTypes.number.isRequired,