WebStorm 9.0.0 Web Help

You can define the code styles that differ from the pre-defined ones. These code style schemes are stored in XML files, in the config/codestyles folder under the user home directory.

You can use the created copy for modifying code styles, and for export.

If you select a code style scheme other than Project, then this code style will be saved for a project. Thus you can assign a global code style for each project.

In this section:

To create a copy of code style settings
  1. In the Code Style page, select the desired scheme from the drop-down list, and click Manage.
  2. In the Code Style Schemes dialog box that opens, click Save As....
  3. In the Save Code Style Scheme As dialog box, type the name of the new scheme.

    WebStorm saves the new code style with the specified name in the config/codestyles/<code_style_name>.xml file under the WebStorm home directory.

  4. Close the Code Style Schemes dialog box, and apply changes.
To copy code style settings to a current project
  1. In the Code Style page, select the desired scheme from the drop-down list, and click Manage.
  2. In the Code Style Schemes dialog box that opens, click Copy to Project:

    copyCodeStyle1.png

    The selected code style is saved in the .idea directory in the file codeStyleSettings.xml.

  3. In the Copy Scheme to Project dialog box, confirm switching to the new scheme, if necessary (Yes):

    copyCodeStyle2.png

    Then close the Code Style Schemes dialog box, and apply changes.

See Also

Procedures:

Reference:

Web Resources: