Created
January 2, 2017 18:27
-
-
Save sirbrillig/34287e440ce745e2349bc6150a218a22 to your computer and use it in GitHub Desktop.
An example of a simple stateless functional React component
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 React from 'react'; | |
export function Header( { title, subtitle, className } ) { | |
return ( | |
<div className={ className }> | |
<h1>{ title }</h1> | |
<span>{ subtitle }</span> | |
</div> | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment