docs: recommend setting e.returnValue (#33628)
This commit is contained in:
parent
68d6d8d451
commit
75ccec7996
1 changed files with 1 additions and 1 deletions
|
@ -473,7 +473,7 @@ window.onbeforeunload = (e) => {
|
||||||
// a non-void value will silently cancel the close.
|
// a non-void value will silently cancel the close.
|
||||||
// It is recommended to use the dialog API to let the user confirm closing the
|
// It is recommended to use the dialog API to let the user confirm closing the
|
||||||
// application.
|
// application.
|
||||||
e.returnValue = false // equivalent to `return false` but not recommended
|
e.returnValue = false
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue