Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Evaluate and replace selectionNew to Visual Studio Code? Get it now.
Evaluate and replace selection

Evaluate and replace selection

Szabolcs Dombi

|
1,410 installs
| (3) | Free
Evaluate and replace selection
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Evaluate and replace selection

preview

Evaluate and replace selection in vscode.

Commands

  • Evaluate and replace selection
  • Evaluate selection in global context

Example

Paste the lines in an empty editor then select them. The extension is dealing only with the selected lines, not the entire file.

  1. Run "Evaluate selection in global context" on the following lines.
    a = 1
    b = 2
    c = "hello"
  1. Run "Evaluate and replace selection" on the following lines.
    1+1
    a*10+b
    c+"world"
    i
    i
    i
  1. You should get the following lines.
    2
    102
    helloworld
    3
    4
    5

Links

  • Github
  • Download page
  • Change log
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft