Skip to content

Instantly share code, notes, and snippets.

@pastelsky
Created March 30, 2017 17:19
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 pastelsky/0c9cbd148953ff1c16cf420304761d44 to your computer and use it in GitHub Desktop.
Save pastelsky/0c9cbd148953ff1c16cf420304761d44 to your computer and use it in GitHub Desktop.
Destructure all things
import React, { Component, PropTypes } from 'react'
class HelloWorld extends Component {
static propTypes = {
show: PropTypes.bool
}
render() {
const { show } = this.state
return ( show && <h1> Destructure all things !</h1> )
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment