aboutsummaryrefslogtreecommitdiff
path: root/files/fr/web/api/workerglobalscope/onoffline
diff options
context:
space:
mode:
authorjulieng <julien.gattelier@gmail.com>2021-10-02 17:20:24 +0200
committerSphinxKnight <SphinxKnight@users.noreply.github.com>2021-10-02 17:30:20 +0200
commit1407c8fdef01ecd0ffb8a8bd46e7113f119b9fde (patch)
tree30a56efd3eff3a01bd1611e1840fdbbfacf544a4 /files/fr/web/api/workerglobalscope/onoffline
parentc05efa8d7ae464235cf83d7c0956e42dc6974103 (diff)
downloadtranslated-content-1407c8fdef01ecd0ffb8a8bd46e7113f119b9fde.tar.gz
translated-content-1407c8fdef01ecd0ffb8a8bd46e7113f119b9fde.tar.bz2
translated-content-1407c8fdef01ecd0ffb8a8bd46e7113f119b9fde.zip
convert content to md
Diffstat (limited to 'files/fr/web/api/workerglobalscope/onoffline')
-rw-r--r--files/fr/web/api/workerglobalscope/onoffline/index.md47
1 files changed, 18 insertions, 29 deletions
diff --git a/files/fr/web/api/workerglobalscope/onoffline/index.md b/files/fr/web/api/workerglobalscope/onoffline/index.md
index e9630579f9..aa4ae2bcaf 100644
--- a/files/fr/web/api/workerglobalscope/onoffline/index.md
+++ b/files/fr/web/api/workerglobalscope/onoffline/index.md
@@ -3,45 +3,34 @@ title: WorkerGlobalScope.onoffline
slug: Web/API/WorkerGlobalScope/onoffline
translation_of: Web/API/WorkerGlobalScope/onoffline
---
-<p>{{APIRef("Web Workers API")}}</p>
+{{APIRef("Web Workers API")}}
-<p>La propriété <strong><code>onoffline</code></strong> de l'interface {{domxref("WorkerGlobalScope")}} représente un {{event("Event_handlers", "event handler")}} à appeler lorsque l'événement {{event("offline")}} survient et se propage à travers le {{domxref("Worker")}}.</p>
+La propriété **`onoffline`** de l'interface {{domxref("WorkerGlobalScope")}} représente un {{event("Event_handlers", "event handler")}} à appeler lorsque l'événement {{event("offline")}} survient et se propage à travers le {{domxref("Worker")}}.
-<h2 id="Syntaxe">Syntaxe</h2>
+## Syntaxe
-<pre>self.onoffline = function() { ... };</pre>
+ self.onoffline = function() { ... };
-<h2 id="Exemple">Exemple</h2>
+## Exemple
-<p>L'extrait de code suivant montre un gestionnaire <code>onoffline</code> placé dans un worker :</p>
+L'extrait de code suivant montre un gestionnaire `onoffline` placé dans un worker :
-<pre class="brush: js">self.onoffline = function() {
+```js
+self.onoffline = function() {
console.log('Your worker is now offline');
-}</pre>
+}
+```
-<h2 id="Spécifications">Spécifications</h2>
+## Spécifications
-<table class="standard-table">
- <tbody>
- <tr>
- <th scope="col">Spécification</th>
- <th scope="col">Statut</th>
- <th scope="col">Commentaire</th>
- </tr>
- <tr>
- <td>{{SpecName('HTML WHATWG', "#handler-workerglobalscope-onoffline", "WorkerGlobalScope.onoffline")}}</td>
- <td>{{Spec2('HTML WHATWG')}}</td>
- <td></td>
- </tr>
- </tbody>
-</table>
+| Spécification | Statut | Commentaire |
+| ------------------------------------------------------------------------------------------------------------------------------------ | -------------------------------- | ----------- |
+| {{SpecName('HTML WHATWG', "#handler-workerglobalscope-onoffline", "WorkerGlobalScope.onoffline")}} | {{Spec2('HTML WHATWG')}} | |
-<h2 id="Compatibilité_des_navigateurs">Compatibilité des navigateurs</h2>
+## Compatibilité des navigateurs
+{{Compat("api.WorkerGlobalScope.onoffline")}}
+## Voir aussi
-<p>{{Compat("api.WorkerGlobalScope.onoffline")}}</p>
-
-<h2 id="Voir_aussi">Voir aussi</h2>
-
-<p>L'interface {{domxref("WorkerGlobalScope")}} à laquelle il appartient.</p>
+L'interface {{domxref("WorkerGlobalScope")}} à laquelle il appartient.