BugdrLog in
All problems
EasyJavaScriptMobile Engineer · components · forwardref · react-native · refs · typescript

Ref forwarding for themed components

★ 0.0 (0 ratings)25 min0 engineers solved this

Your assignment

This is a styling library for React Native that turns style props into native style arrays using a theme. Its main parts are the theme provider and context, style functions (such as backgroundColor and spacing) that map props to style values, a hook that applies a list of style functions to props and handles responsive breakpoints, and component factories (createBox, createText, createRestyleComponent) that wrap a base component. Callers use the factories to build their own components, pass theme keys or responsive values as props, and render them like the underlying component. Tests live in src/test and use react-test-renderer with Jest.

What the team is seeing

incident log
Our app's custom themed components stop responding when a parent screen tries to reach them directly, so focusing a field or measuring a card from the parent does nothing. Everything looks fine on screen, but the screen cannot get hold of the component it created.

Acceptance checks 1

  • Check 1

Discussion is locked — log in and complete this problem to join the discussion and rate your experience.