Created
May 17, 2018 17:18
-
-
Save EdsonAlcala/5a8958eeec7cb2e91e5afa3c02f6d71c to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| import * as React from 'react'; | |
| interface Props { | |
| name?: string; | |
| } | |
| const Header: React.SFC<Props> = (props: Props) => ( | |
| <h1> | |
| Hello, {props.name}! Welcome to React and TypeScript. | |
| </h1> | |
| ); | |
| Header.defaultProps = { | |
| name: 'world', | |
| }; | |
| export default Header; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment