useFocusedObject

@FocusedObject: the object of this type that the focused view, one of its ancestors, or the focused scene publishes with focusedObject or focusedSceneObject, or null. The component re-renders when focus moves and when the object changes.

Declaration

React
function useFocusedObject<T extends ObservableObject>(
  type: ObservableObjectType<T>
): Observed<T> | null

Parameters

  • type*ObservableObjectType<T>

See also

More in Hooks.