Skip to content

Instantly share code, notes, and snippets.

@tuxsudo
Created October 24, 2016 17:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tuxsudo/ab63177bc2591a7eb7dd118cf7242e68 to your computer and use it in GitHub Desktop.
Save tuxsudo/ab63177bc2591a7eb7dd118cf7242e68 to your computer and use it in GitHub Desktop.
An example of a component that will just pass along all props
const Component = ({title, subtitle, className, ...props}) => (
<a className={`myClass ${className}`} {...props}>
<h1>{title}</h1>
<h2>{subtitle}</h2>
</a>
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment