blob: 6de5318d51c0c1e3340e98cf6ca77961c425cdd2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
---
title: Notification.onclose
slug: Web/API/notification/onclose
tags:
- API
- API Notifications
- Notification
- Notifications
- Propriété
- Reference
- onclose
translation_of: Web/API/Notification/onclose
---
{{APIRef("Web Notifications")}}{{AvailableInWorkers}}{{securecontext_header}}
La propriété **`onclose`** de l'interface {{domxref ("Notification")}} définit un écouteur d'événements pour recevoir les événements {{domxref ("HTMLDialogElement/close_event", "close")}}. Ces événements se produisent lorsqu'une {{domxref ("Notification")}} est fermée.
## Syntaxe
Notification.onclose = function(event) { ... }
Notification.onclose = (event) => { ... }
## Compatibilité des navigateurs
{{Compat("api.Notification.onclose")}}
## Voir également
- {{domxref("Notification")}}
- [Utilisation de l'API Notifications](/fr/docs/Web/API/Notifications_API/Using_the_Notifications_API)
|