Skip to content
This repository has been archived by the owner on Nov 10, 2023. It is now read-only.

Commit

Permalink
Fix issue where error wasn't throwing in suspense mode
Browse files Browse the repository at this point in the history
  • Loading branch information
jxom committed Mar 6, 2020
1 parent 29419b2 commit 63fdae6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/useLoads.ts
Original file line number Diff line number Diff line change
Expand Up @@ -488,6 +488,9 @@ export function useLoads<Response, Err>(
load()();
}
}
if (states.isRejected) {
throw record.error;
}
}

return React.useMemo(
Expand Down

0 comments on commit 63fdae6

Please sign in to comment.