Skip to content

Commit 6b6b67d

Browse files
committed
Add a warning about providing a rejection handler.
1 parent 4bd65be commit 6b6b67d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -686,6 +686,9 @@ A reference to the internal wrapper promise created when starting a new promise
686686
`run` / `reload`). It fulfills or rejects along with the provided `promise` / `promiseFn` / `deferFn`. Useful as a
687687
chainable alternative to the `onResolve` / `onReject` callbacks.
688688

689+
Warning! If you chain on `promise`, you MUST provide a rejection handler (e.g. `.catch(...)`). Otherwise React will
690+
throw an exception and crash if the promise rejects.
691+
689692
#### `run`
690693

691694
> `function(...args: any[]): void`

0 commit comments

Comments
 (0)