2

Is there is any shortcut to wrap in braces or quotes selected text/word in vscodevim plugin?

Thanks in advance!

Gama11
  • 31,714
  • 9
  • 78
  • 100
i474232898
  • 781
  • 14
  • 25

2 Answers2

4

Vscodevim replicates the functionality of the surround-vim plugin, which means it provides a couple of operators to deal with surrounding.

In your case, ys should help you. On a visual selection, ys" will add quotes.

More on this here

Axnyff
  • 9,213
  • 4
  • 33
  • 37
0

Hi the extension in VS Code works for me; the syntax is:

y s <motion> <desired>

So one example would be:

ysw"

  • w -> motion to define from your cursor till the end of that word

  • " -> What should surround the word

Note that motion will define what is surrounded. Therefore you can write

ysiw"

  • iw -> surrounding the word not dependent on your cursor