Preparing search index...
The search index is not available
React Router API Reference
React Router API Reference
react-router
useBeforeUnload
Function useBeforeUnload
use
Before
Unload
(
callback
,
options
?
)
:
void
Setup a callback to be fired on the window's
beforeunload
event.
Parameters
callback
:
(
(
event
:
BeforeUnloadEvent
)
=>
any
)
(
event
)
:
any
Parameters
event
:
BeforeUnloadEvent
Returns
any
Optional
options
:
{
capture
?:
boolean
;
}
Optional
capture
?:
boolean
Returns
void
Settings
Member Visibility
Protected
Inherited
External
Theme
OS
Light
Dark
React Router API Reference
Loading...
Setup a callback to be fired on the window's
beforeunload
event.