Skip to content

Instantly share code, notes, and snippets.

@ReidWilliams

ReidWilliams/component.js

Last active Nov 21, 2018
Embed
What would you like to do?
React + styled-components template
import React from 'react'
import PropTypes from 'prop-types'
import styled from 'styled-components'
// locals
// import { theme } from 'styles'
const Root = styled.div``
class MyComponent extends React.Component {
render() {
const { className } = this.props
return (
<Root className={className}>
</Root>
)
}
}
MyComponent.propTypes = {
className: PropTypes.string
}
MyComponent.defaultProps = {
className: ''
}
export default MyComponent
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.