Last active
May 4, 2019 11:24
Star
You must be signed in to star a gist
Higher-Order Components
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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