Skip to content
Source
Sign inSign up
TanStack/query

rename useErrorBoundary #4677

Send to my agent
ClosedTkDodo opened this issue 1 comment
TkDodocommented

context

A property that starts with the prefix use is unfortunately named, as use usually indicates a hook in React. ErrorBoundary might also be a quite react specific term.

Renaming the property to e.g. throwError would more accurately describe what is happening: the error will be thrown. In React, it will be picked up by the nearest error boundary.

proposal

  • rename useErrorBoundary to throwError
  1. TkDodo added labelsv5

  2. Should this issue be assigned to me then?

  3. TkDodo closed this

Sign in to join this conversation.