Skip to content

Instantly share code, notes, and snippets.

@heymartinadams
Last active September 26, 2019 17:33
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 heymartinadams/f4de57627469ca4e6f4b7cc6a5324758 to your computer and use it in GitHub Desktop.
Save heymartinadams/f4de57627469ca4e6f4b7cc6a5324758 to your computer and use it in GitHub Desktop.
// Button, stateless functional component
// Pass a special class from parent component (e.g. “capps-button flat”)
// to affect appearance. Otherwise, “capps-button primary” is the default.
import React from 'react'
export default ({ action, className, text }) => (
<div className={className ? className : 'app-button dark'} onTouchTap={action}>{text}</div>
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment