Higher Order Components

Download reactjs eBook

Introduction

Higher Order Components ("HOC" in short) is a react application design pattern that is used to enhance components with reusable code. They enable to add functionality and behaviors to existing component classes.

A HOC is a pure javascript function that accepts a component as it's argument and returns a new component with the extended functionality.

Remarks

HOCs are pretty often used in third party libraries. Such as the Redux connect function.

Related Examples

Stats

92 Contributors: 1
Wednesday, April 26, 2017
Licensed under: CC-BY-SA

Not affiliated with Stack Overflow
Rip Tutorial: info@zzzprojects.com

Download eBook