Remix
useNavigate
Use `useNavigate` hook
To trigger the progress bar when navigating with useNavigate, you need to use the useNavigate
hook in @bprogress/remix
, which wraps the remix hook by adding the progress bar.
Import
Usage
See the Remix useNavigate
hook documentation for more information.
Options
Name | Type | Default | Description |
---|---|---|---|
showProgress | boolean | true | Show the progress bar. |
startPosition | number | undefined | The start position of the progress bar. |
disableSameURL | boolean | true | Disable the progress bar when the URL is the same. |
delay | number | undefined | The delay before the progress bar starts. |
stopDelay | number | undefined | The delay before the progress bar stops. |
customNavigate | () => NavigateFunction | undefined | A custom navigate instance. |
NavigateProgressOptions
Note
By default, if you do not specify any options when using navigate, the options
defined during the initialization of the useNavigate
hook will be applied.
However, if you provide specific options when using navigate, these will take
precedence and override the default options set in the hook.