This is a React HOC to get the box model values of the root wrapper.
It takes follwing arguments as comma seperated strings in addition to the component -
- height
- width
- borderWidth
- borderTopWidth
- borderBottomWidth
- borderRightWidth
- borderLeftWidth
- padding
- paddingTop
- paddingBottom
- paddingRight
- paddingLeft
- margin
- marginTop
- marginBottom
- marginRight
- marginLeft
Invalid arguments will throw a consol error.
Please view this Codepen example