aboutsummaryrefslogtreecommitdiff
path: root/files/fr/web/api/worker/terminate/index.md
diff options
context:
space:
mode:
Diffstat (limited to 'files/fr/web/api/worker/terminate/index.md')
-rw-r--r--files/fr/web/api/worker/terminate/index.md58
1 files changed, 23 insertions, 35 deletions
diff --git a/files/fr/web/api/worker/terminate/index.md b/files/fr/web/api/worker/terminate/index.md
index 6565192498..92f8b0d8b1 100644
--- a/files/fr/web/api/worker/terminate/index.md
+++ b/files/fr/web/api/worker/terminate/index.md
@@ -3,56 +3,44 @@ title: Worker.terminate()
slug: Web/API/Worker/terminate
translation_of: Web/API/Worker/terminate
---
-<p>{{ apiref("Worker") }}</p>
+{{ apiref("Worker") }}
-<p>La méthode <code> <strong>terminate()</strong></code> de l'interface {{domxref("Worker")}} termine immédiatement le {{domxref("Worker")}}. Cette interruption ne permet pas au worker de finaliser ses opérations, il est juste arrêté sur le champ.</p>
+La méthode **`terminate()`** de l'interface {{domxref("Worker")}} termine immédiatement le {{domxref("Worker")}}. Cette interruption ne permet pas au worker de finaliser ses opérations, il est juste arrêté sur le champ.
-<h2 id="Syntaxe">Syntaxe</h2>
+## Syntaxe
-<pre class="brush: js">myWorker.terminate();</pre>
+```js
+myWorker.terminate();
+```
-<h3 id="Paramètres">Paramètres</h3>
+### Paramètres
-<p>Aucun.</p>
+Aucun.
-<h3 id="Valeur_de_retour">Valeur de retour</h3>
+### Valeur de retour
-<p>Néant.</p>
+Néant.
-<h2 id="Exemple">Exemple</h2>
+## Exemple
-<p>L'extrait de code suivant montre la création d'un objet {{domxref("Worker")}} en utilisant le constructeur {{domxref("Worker.Worker", "Worker()")}}, qui est alors immédiatement interrompu.</p>
+L'extrait de code suivant montre la création d'un objet {{domxref("Worker")}} en utilisant le constructeur {{domxref("Worker.Worker", "Worker()")}}, qui est alors immédiatement interrompu.
-<pre class="brush: js">var myWorker = new Worker("worker.js");
+```js
+var myWorker = new Worker("worker.js");
myWorker.terminate();
-</pre>
-
-<h2 id="Spécifications">Spécifications</h2>
-
-<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', "#dom-worker-terminate", "Worker.terminate()")}}</td>
- <td>{{Spec2('HTML WHATWG')}}</td>
- <td></td>
- </tr>
- </tbody>
-</table>
+```
-<h2 id="Compatibilité_des_navigateurs">Compatibilité des navigateurs</h2>
+## Spécifications
-<div>
+| Spécification | Statut | Commentaire |
+| ---------------------------------------------------------------------------------------------------- | -------------------------------- | ----------- |
+| {{SpecName('HTML WHATWG', "#dom-worker-terminate", "Worker.terminate()")}} | {{Spec2('HTML WHATWG')}} | |
+## Compatibilité des navigateurs
-<p>{{Compat("api.Worker.terminate")}}</p>
-</div>
+{{Compat("api.Worker.terminate")}}
-<h2 id="Voir_aussi">Voir aussi</h2>
+## Voir aussi
-<p>L'interface {{domxref("Worker")}} à laquelle elle appartient.</p>
+L'interface {{domxref("Worker")}} à laquelle elle appartient.