Skip to content

Instantly share code, notes, and snippets.

@alexhayes
Created November 10, 2015 11:32
Show Gist options
  • Save alexhayes/f9fab8dba74876c7cecc to your computer and use it in GitHub Desktop.
Save alexhayes/f9fab8dba74876c7cecc to your computer and use it in GitHub Desktop.
react-addons-pure-render-mixin using ES6 classes in React
import React from 'react'
import {shouldComponentUpdate} from 'react-addons-pure-render-mixin'
export default class extends React.Component {
shouldComponentUpdate = shouldComponentUpdate
static propTypes ={
disabled: React.PropTypes.bool,
}
}
// https://gist.github.com/acdlite/453f227f5e5cbbf105f8
// https://github.com/gaearon/react-pure-render
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment