Skip to content

Commit

Permalink
Merge pull request javascript-tutorial#2906 from vabushkevich/form-mu…
Browse files Browse the repository at this point in the history
…ltipart-fix

fix: replace `form/multipart` with `multipart/form-data`
  • Loading branch information
iliakan authored Apr 14, 2022
2 parents ed8e41a + 21d5bc7 commit 06b8b1d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions 5-network/01-fetch/article.md
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ To make a `POST` request, or a request with another method, we need to use `fetc
- **`method`** -- HTTP-method, e.g. `POST`,
- **`body`** -- the request body, one of:
- a string (e.g. JSON-encoded),
- `FormData` object, to submit the data as `form/multipart`,
- `FormData` object, to submit the data as `multipart/form-data`,
- `Blob`/`BufferSource` to send binary data,
- [URLSearchParams](info:url), to submit the data in `x-www-form-urlencoded` encoding, rarely used.

Expand Down Expand Up @@ -304,7 +304,7 @@ Response properties:
Methods to get response body:
- **`response.text()`** -- return the response as text,
- **`response.json()`** -- parse the response as JSON object,
- **`response.formData()`** -- return the response as `FormData` object (form/multipart encoding, see the next chapter),
- **`response.formData()`** -- return the response as `FormData` object (`multipart/form-data` encoding, see the next chapter),
- **`response.blob()`** -- return the response as [Blob](info:blob) (binary data with type),
- **`response.arrayBuffer()`** -- return the response as [ArrayBuffer](info:arraybuffer-binary-arrays) (low-level binary data),

Expand Down

0 comments on commit 06b8b1d

Please sign in to comment.