microsoft / microsoft/TypeScript

Autocompletion is not working for TypeScript paths alias in import statements when omitting "baseUrl"

Aperta
#54,295 0 commenti 0 reazioni 1 assegnatario Vedi su GitHub

@rbuckton ci sta già lavorando.

Dal 23/5/2023.

Needs Investigation Rescheduled
Lingua principale
Go
Stelle
111k
Fork
14.3k
Merge medio
1g 19h
PR unite (30g)
117

Descrizione

Does this issue occur when all extensions are disabled?: Yes/No

  • VS Code Version: Version: 1.79.0-insider
  • OS Version: Darwin arm64 22.4.0

Steps to Reproduce:

  1. Create a tsconfig.json with paths alias without specifying a "baseUrl":
{
  "compilerOptions": {
    "paths": {
      "~/*": ["./src/*"],
    },
  },
}
  1. Try to trigger the autocompletion:
image

If baseUrl is set like "baseUrl": ".", here is the result of the autocompletion:
image

As baseUrl is optional since TypeScript 4.1, shouldn't VS Code set it to the same folder path where the tsconfig.json is located if omitted?

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.