WebStorm 2020.3 Help

WebStorm projects

Whatever you do in WebStorm, you do that in the context of a project. A project in WebStorm is a folder with the source code you edit, the libraries and tools you use (for example, in the node_modules subfolder), and various app configuration files (for example, package.json or .eslintrc ).

Once you have opened a folder in WebStorm, the .idea subfolder is added to it where WebStorm stores its internal configuration settings, for example, for the project code style or the version control system.

All the settings files in the .idea directory should be put under version control except workspace.xml, which stores your local preferences. The workspace.xml file should be marked as ignored by VCS.

WebStorm does not support direct editing of files on remote hosts. Therefore to work with remote sources in WebStorm, you need to download them, open the folder where they are stored, and arrange them in a WebStorm project, as described in Creating a project from existing local sources. To keep your local and remote sources synchronized, configure automatic upload using the Upload changed files automatically to the default server list in the Deployment Options dialog.

Switch between projects

If you have several opened projects at the same time, you can switch between them using the following options:

  • Switch to the next project window: Ctrl+Alt+] (Window | Next Project Window)

  • Switch to the previous project window: Ctrl+Alt+[ (Window | Previous Project Window)

  • Alternatively, open the Window menu and select the project to which you want to switch.

Rename projects

  1. Right-click the root folder of your project and select Refactor | Rename from the context menu or press Shift+F6.

  2. In the dialog that opens, choose the rename strategy.

    • If the project name is the same as the name of its root folder, select Rename directory.

    • If the project name is different from the name of its root folder, select Rename project.

      Alternatively, select File | Rename Project from the main menu and type the new name of the project in the dialog that opens.

      Also select this option if your application is deployed to a remote server and the project root folder is mapped to the server root.

    Of course, you can rename the root folder and update the mapping in the server configuration accordingly, see Configure synchronization with a Web server for details.

Move a project to another location

  1. In the Project tool window Alt+1, right-click the root directory of your project and select Refactor | Move directory (F6 ).

  2. In the dialog that opens, specify a new location for the project and click Refactor.

    Moving a project to another location

Change the default location for projects

In WebStorm, you can specify the default parent folder for your projects. WebStorm will start with this folder when you open projects. This default location will be also suggested every time you create a new project.

  1. Open the Settings/Preferences dialog Ctrl+Alt+S and go to Appearance & Behavior | System Settings.

  2. In the Default directory field, specify the path to the folder in which you want to store your projects.

    Changing the default location for projects

    Next time you create a project, WebStorm will suggest the specified directory as the parent for the new project.

    Creating a new project: the default location suggested
Last modified: 08 March 2021