Skip to content

Instantly share code, notes, and snippets.

@mohandere
Last active May 4, 2019 11:24
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save mohandere/0314912b8803ae5295421ac74132fa32 to your computer and use it in GitHub Desktop.
Higher-Order Components
import React from 'react'
const higherOrderComponent = WrappedComponent => {
class HOC extends React.Component {
render() {
return <WrappedComponent />
}
}
return HOC
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment