Skip to content

Commit 99dcf8b

Browse files
committed
Conflicts fixed on "Fetch" page in french language
1 parent c424fe9 commit 99dcf8b

File tree

1 file changed

+2
-25
lines changed

1 file changed

+2
-25
lines changed

5-network/01-fetch/article.md

Lines changed: 2 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -191,21 +191,12 @@ Ces en-têtes assurent un HTTP correct et sûr, ils sont donc contrôlés exclus
191191
192192
Pour faire une requête `POST`, ou une requête avec une autre méthode, nous devons utiliser les options `fetch` :
193193
194-
<<<<<<< HEAD
195194
- **`method`** -- HTTP-method, par exemple `POST`,
196195
- **`body`** -- le corps de la requête, un parmi ceux-ci :
197196
- une chaîne de caractères (par exemple encodé en JSON),
198-
- un objet `FormData`, pour soumettre les données en tant que `form/multipart`,
197+
- un objet `FormData`, pour soumettre les données en tant que `multipart/form-data`,
199198
- `Blob`/`BufferSource` pour envoyer des données binaires,
200199
- [URLSearchParams](info:url), pour soumettre les données au format `x-www-form-urlencoded`, rarement utilisé.
201-
=======
202-
- **`method`** -- HTTP-method, e.g. `POST`,
203-
- **`body`** -- the request body, one of:
204-
- a string (e.g. JSON-encoded),
205-
- `FormData` object, to submit the data as `multipart/form-data`,
206-
- `Blob`/`BufferSource` to send binary data,
207-
- [URLSearchParams](info:url), to submit the data in `x-www-form-urlencoded` encoding, rarely used.
208-
>>>>>>> bf7d8bb1af3b416d393af1c15b03cb1352da1f9c
209200
210201
Le format JSON est utilisé la plupart du temps.
211202
@@ -304,7 +295,6 @@ fetch(url, options)
304295
.then(result => /* process result */)
305296
```
306297
307-
<<<<<<< HEAD
308298
Propriétés de réponse :
309299
- `response.status` -- Code HTTP de la réponse,
310300
- `response.ok` -- `true` est le statut 200-299.
@@ -313,22 +303,9 @@ Propriétés de réponse :
313303
Méthodes pour obtenir le corps de réponse :
314304
- **`response.text()`** -- retourne la réponse sous forme de texte,
315305
- **`response.json()`** -- analyse la réponse en tant qu'objet JSON,
316-
- **`response.formData()`** -- retourne la réponse en tant qu'objet `FormData` (encodage formulaire/multipartie, voir le chapitre suivant),
306+
- **`response.formData()`** -- retourne la réponse en tant qu'objet `FormData` (encodage `multipart/form-data`, voir le chapitre suivant),
317307
- **`response.blob()`** -- retourne la réponse en tant que [Blob](info:blob) (données binaires avec type),
318308
- **`response.arrayBuffer()`** -- retourne la réponse en tant que [ArrayBuffer](info:arraybuffer-binary-arrays) (données binaires de bas niveau),
319-
=======
320-
Response properties:
321-
- `response.status` -- HTTP code of the response,
322-
- `response.ok` -- `true` if the status is 200-299.
323-
- `response.headers` -- Map-like object with HTTP headers.
324-
325-
Methods to get response body:
326-
- **`response.text()`** -- return the response as text,
327-
- **`response.json()`** -- parse the response as JSON object,
328-
- **`response.formData()`** -- return the response as `FormData` object (`multipart/form-data` encoding, see the next chapter),
329-
- **`response.blob()`** -- return the response as [Blob](info:blob) (binary data with type),
330-
- **`response.arrayBuffer()`** -- return the response as [ArrayBuffer](info:arraybuffer-binary-arrays) (low-level binary data),
331-
>>>>>>> bf7d8bb1af3b416d393af1c15b03cb1352da1f9c
332309
333310
Options de fetch jusque là :
334311
- `method` -- Méthode HTTP,

0 commit comments

Comments
 (0)