Last active
November 4, 2015 08:47
-
-
Save terrierscript/8f075d5998f94ab14d9e to your computer and use it in GitHub Desktop.
Stateless functional componentsでnull返してはまった話 ref: http://qiita.com/inuscript/items/05469cc3787de4e6a49a
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const FooItem = ({ show }) => { | |
if(!show){ | |
return null | |
} | |
return ( | |
<div>some component</div> | |
) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const FooItem = ({ show }) => { | |
if(!show){ | |
return null | |
} | |
return ( | |
<div>some component</div> | |
) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const FooItem = ({ show }) => { | |
if(!show){ | |
return <noscript /> | |
} | |
return ( | |
<div>some component</div> | |
) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const FooItem = ({ show }) => { | |
if(!show){ | |
return <noscript /> | |
} | |
return ( | |
<div>some component</div> | |
) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment