v4.0.0
v4.0.0
π π π We've released v4 of ui-box!
Breaking Changes:
innerRef
is gone. Useref
(ui-box forwards refs to the underlying component)- Types have been updated and may break depending on how you previously were using them
Highlights
The types have been much improved for better polymorphic support. Inspired by types from Emotion and https://github.com/kripod/react-polymorphic-box we now have better support for polymorphic props when using the is
prop. This worked before, but there were some limitations β namely using React.ComponentProps<typeof Box>
would break and we didn't have a sane way to give you more type-safety.
Now you can also type your own components that extend ui-box
by casting them as BoxComponent<ElementType, Props>