🛑 STOP Renaming Things in VS Code This Way!

preview_player
Показать описание

🔥 VS Code Tip of the Day 🔥
How do you rename functions, variables, classes, and other symbols in visual studio code?
Do you go one by one renaming them? I hope not.
Do you use the find and replace menu to replace them all? That’s better.
Maybe you use Ctrl+D or Ctrl+Shift+L to select all occurrences of that word. That could work, but it’s still not the easiest way.
All you have to do is put your cursor on the symbol that you want to rename and press F2, then rename it. That’s it. It will automatically be renamed everywhere that it’s referenced.
You’re welcome!
_____________________________________

🛠️ Tools I use:
_____________________________________

💖 Show support!
_____________________________________

👀 Watch Next:
_____________________________________

🌐 Connect With Me:
_____________________________________

** Affiliate Disclaimer: Some of the above links may be affiliate links, which may generate me a sales commission at no additional cost to you.

#codeSTACKr #vscode #learntocode
Рекомендации по теме
Комментарии
Автор

Woah!! That's amazing. I previously used to do with `CTRL+SHIFT+L`. But this one is really better; it even modifies the references in other files. And what's another cool thing is that you can preview the changes if you hit `SHIFT+ENTER` Instead of just `ENTER` after giving it a new name. Thanks for sharing, man!

darkstardream
Автор

Using it for my Web Development App class…thanks boss

Chris-nqri
Автор

I have been searching for this in a time

t.h.e.unknown_
Автор

This is a very nice tip, I've been doing it the wrong way 😫

mayowasunusi
Автор

Yeah it's cool but f2 is far for the fingers to rich normally and most of the laptop uses fn to control function keys which makes combinations of fn+f2 so i will prefer ctrl+d or ctrl+shift+l

echonabin