Better support for multipart/form-data file upload examples
- Langage dominant
- TypeScript
- Étoiles
- 1.2k
- Forks
- 242
- Métriques de merge des PR
- Aucune PR mergée en 30 j
Description
Currently in the JS / Fetch example, it shows multipart file uploads like so:

This doesn't work as it just sends the string "logo.png" instead of the file.
A better example might be:
```js
// HTML file input, chosen by user
const fileInputs = document.querySelectorAll('input[type="file"]')
form.append("file", fileInputs[0].files[0]);
```
Guide de contribution
Ouvrir le guide de contribution
Piste de recherche
Start by locating the JS/Fetch multipart/form-data example and the code that generates its file-upload snippet. Compare the current output with the issue's File-based example, then verify that generated multipart examples reference the selected file rather than the string "logo.png".
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- javascript, typescript
- Domaine
- tooling, web-dev
- Type d'issue
- Bug
- Difficulté
- 3/5
- Temps estimé
- 1-2 jours
- Activité
- À l'abandon
- Clarté
- Plutôt claire
- Accessibilité débutants
- 45/100