microsoft / microsoft/TypeScript

Shortcut for creating local variable from all occurrences

Open
#57,448 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Awaiting More Feedback Suggestion
Dominant language
Go
Stars
111k
Forks
14.3k
Avg merge
1d 19h
Merged PRs (30d)
117

Description

If there is not already, there should be support for refactoring(creating local variable of) all instances of a selection. The images show a before and after of what I am looking to do. I tried creating a shortcut with multiple commands where the first selects all instances then the second refactors the lines, but this is not yet possible.

IMG_8923
IMG_8924

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

The issue names no files, tests, or entry points. Start by determining whether the request belongs in the editor's shortcut or refactoring subsystem and inspect how selecting all occurrences is currently handled. Done means a shortcut can apply the requested local-variable refactoring to all selected occurrences.

Written by the indexing model from the issue text.

Assessment

Domain
developer-experience, tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.