Skip to content

AccessibilityInfo.setAccessibilityFocus is not implemented for TouchableWithoutFeedback #8498

@MicrosoftNik

Description

@MicrosoftNik

Have been trying to set the accessibility focus of a TouchableWithoutFeedback component upon rendering of the page.

const refT = React.useRef(null);

React.useEffect(() => {
  if (false && refT && refT.current) {
    const reactTag = findNodeHandle(refT.current) || 0;
    AccessibilityInfo.setAccessibilityFocus(reactTag);
  }
}, [refT]);

return (
  <TouchableWithoutFeedback
    ref={refT}
...

React Native throws the error:
unable to get property typeViewFocused of undefined or null reference.

Tried with react-native-windows versions 0.64.14 and 0.65.0.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions