aboutsummaryrefslogtreecommitdiff
path: root/files/fr/web/api/notification/onshow/index.md
blob: 83f739f73e7fe70eb3d7cb997e1fb4fc4059ee11 (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.onshow
slug: Web/API/notification/onshow
tags:
  - API
  - API Notifications
  - Notification
  - Notifications
  - Propriété
  - Reference
  - onshow
translation_of: Web/API/Notification/onshow
---
{{APIRef("Web Notifications")}}{{AvailableInWorkers}}{{securecontext_header}}

La propriété **`onshow`** de l'interface {{domxref ("Notification")}} définit un écouteur d'événements pour recevoir des événements {{domxref ("Element/show_event", "show")}}. Ces événements se produisent lorsqu'une {{domxref ("Notification")}} est affiché.

## Syntaxe

    Notification.onshow = function() { ... }
    Notification.onshow = () => { ... }

## Compatibilité des navigateurs

{{Compat("api.Notification.onshow")}}

## Voir également

- {{domxref("Notification")}}
- [Utilisation de l'API Notifications](/fr/docs/Web/API/Notifications_API/Using_the_Notifications_API)