File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
packages/react-router/lib Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -324,12 +324,13 @@ function useIsomorphicLayoutEffect(
324
324
* Declarative mode versus Data/Framework mode - the primary difference being
325
325
* that the latter is able to return a stable reference that does not change
326
326
* identity across navigations. The implementation in Data/Framework mode also
327
- * returns a `Promise` that resolves when the navigation is completed. This means
328
- * the return type of `useNavigate` is `void | Promise<void>`. This is accurate,
329
- * but can lead to some red squigglies based on the union in the return value:
327
+ * returns a [`Promise`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise)
328
+ * that resolves when the navigation is completed. This means the return type of
329
+ * `useNavigate` is `void | Promise<void>`. This is accurate, but can lead to
330
+ * some red squigglies based on the union in the return value:
330
331
*
331
332
* - If you're using `typescript-eslint`, you may see errors from
332
- * [`@typescript-eslint/no-floating-promises`](https://typescript-eslint.io/rules/no-floating-promises/ )
333
+ * [`@typescript-eslint/no-floating-promises`](https://typescript-eslint.io/rules/no-floating-promises)
333
334
* - In Framework/Data mode, `React.use(navigate())` will show a false-positive
334
335
* `Argument of type 'void | Promise<void>' is not assignable to parameter of
335
336
* type 'Usable<void>'` error
You can’t perform that action at this time.
0 commit comments