Home > Blockchain >  Is there a shortcut to change both quotes enclosing a string?
Is there a shortcut to change both quotes enclosing a string?

Time:01-30

For example:

const greet = 'Hello!'

I want to change the single-quotes to double-quotes...

const greet = "Hello!"

...where I just select/highlight the first single-quote and overwrite it with a double-quote and automatically have the closing single-quote changed as well?

I mean, I could do a selection on the first single-quote then Ctrl Shift L, which will show multiple cursors that will allow me to do it, but it does it for all the single-quotes. I only want it done on a single string or that one line only.

Is there a shortcut for this? (something like editor.linkedEditing setting)

CodePudding user response:

Select the first quote, then Ctrl D

Thanks to @rioV8!

  •  Tags:  
  • Related