The documentation for WebStorm says if you want to rename a file, do it in the Project Tool window. The problem is that finding a file in the Project Tool window is a hassle. If you start typing there to find the file, it won't be able to locate it unless it is in an expanded folder.
How can I easily rename a file in WebStorm?
Find the file you want to rename, select it and select Rename on the ribbon (or press F2 on your keyboard). Type the new name you want the file to have and press Enter.
You can press and hold the Ctrl key and then click each file to rename. Or you can choose the first file, press and hold the Shift key, and then click the last file to select a group.
Using a Keyboard ShortcutSelect a file or folder with the arrow keys, or start typing the name. Once the file is selected, press F2 to highlight the name of the file. After you type in a new name, press the Enter key to save the new name.
There is no way to rename file right from the editor. Try Navigate/Select In.../Project view to open a file in Project Tool window and then use Refactor/rename in its right-click menu You can also enable the 'Autoscroll from source' Project tool window option to have the currently opened file auto-selected in the project tree
Also, Refactor/rename is available in file right-click menu in the Navigation Bar if it's enabled (View/Navigation bar)
In addition to that, You can use the shourtcut.
Click on the file in the project window & Press the buttton Shift+F6.
Right click on the file -> Refactor -> Rename or just use Shift+F6 as a shortcut and a dialog window will open up so you can change the name.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With