doc: Clarify what <string> means in path option of fs.readFile, fs.readFileSync etc.
Nessuno ha ancora preso questa issue.
- Lingua principale
- JavaScript
- Stelle
- 122k
- Fork
- 37.3k
- Merge medio
- 4g 2h
- PR unite (30g)
- 283
Descrizione
- Version: 14.15.3 x64
- Platform: Windows 10 64-bit
- Subsystem: fs
Affected URL(s):
https://nodejs.org/dist/latest-v14.x/docs/api/fs.html#fs_fs_readfile_path_options
https://nodejs.org/dist/latest-v14.x/docs/api/fs.html#fs_fs_readfilesync_path_options
Description
I am not sure if this a documentation issue or a bug. I get a ENOENT error when I use a url string as path for fs.readFile. However, if I convert the url string to a file path, I am able to read the file.
It needs to be clarified if path strings are exclusively file paths and not urls. If it can also be a url string (and I see no reason for not supporting them?) , then this is bug/feature request!
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Inizia con gli URL della documentazione interessata sull’opzione path di fs.readFile e fs.readFileSync. Controlla come la documentazione descrive attualmente i percorsi di tipo string e chiarisci se si riferiscono solo ai percorsi dei file o anche agli URL, usando una formulazione coerente in entrambe le sezioni.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- javascript, node.js
- Ambito
- documentation
- Tipo di issue
- Documentazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Stato di attività
- Tranquilla
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 55/100