microsoft / microsoft/TypeScript

Getting completions when writing out a dot in a parameter should suggest the splat operator

Open
#4,262 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Help Wanted Suggestion
Dominant language
Go
Stars
111k
Forks
14.3k
Avg merge
2d 4h
Merged PRs (30d)
132

Description

At present the completions returned seem arbitrary. Example:

function(arg: string, ./**/): any {
}

Getting completions at the marker yields the typical alphabetical list of global things - worse yet, in VSCode, pressing . again auto-completes the first one (.AbstractWorker. isn't really a valid argument name)! Very frustrating.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the completion behavior at the marker in the parameter example, including the VSCode case where pressing . selects the first global suggestion. Trace the TypeScript completion path for a dot in a parameter and make the completed suggestions include the splat operator rather than arbitrary global names; verify that the invalid .AbstractWorker. outcome no longer occurs.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
compilers, devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.