WebStorm 9.0.0 Web Help

File | Settings | Editor | Language Injections


For the Language Injections page to be available, the IntelliLang plugin must be enabled.

Use this page to manage the list of available language injections and to configure the language injection feature for text, attributes, and parameters.

To sort the information, use the cells in the header row (Name, Language and Scope). To perform other tasks, use the check boxes and the toolbar icons.

In this section:

Prerequisites

Before you start working with language injections, make sure that IntelliLang plugin is enabled.

The plugin is bundled with WebStorm and activated by default. If not, enable the plugin as described in Enabling and Disabling Plugins.

Injection entries

You can sort the information by any of the columns by clicking the cells in the header row. The current sorting status is shown by the corresponding sorting marker: sortMarkerAsc for the ascending order or sortMarkerDesc for the descending order.

Item Description
Leftmost column Use the check boxes to enable or disable the corresponding injections.

You can also enable or disable a number of injections at once. To do that, select the required injections in the list and click Enable Selected Injections svnSelectAll.png or Disable Selected Injections iconUnSelectAllRemoteRunDialog.gif on the toolbar.

Name This column shows the names of the injections and the libraries that implement them.
Language This column shows the languages to which the corresponding injections pertain.
Scope One of the following:
  • Built-in. This is a category for pre-defined injections. In terms of the scope, those are IDE-level injections.
  • IDE. User-defined injections that are available in all of your projects.
  • Project. User-defined injections that are available only in the current project.

You can move the user-defined injections between the IDE and the project levels by using icon_injection_move_to_project_make_global on the toolbar.

Toolbar

Item Tooltip and Shortcut Description
add.png Add
Insert
Use this icon or shortcut to create a new entry. Select the target category from the list and then specify the settings in the dialog that opens.
delete.png Remove
Delete
Use this icon or shortcut to remove the selected entries from the list.
properties.gif Edit
Enter
Click this icon to re-configure the selected entry in the Language Injection Settings dialog box that opens.
copy.gif Duplicate Use this icon to create a copy of the selected injection entry. Edit the copy as necessary.
svnSelectAll.png Enable Selected Injections Click this icon to enable the injections that are currently selected in the list.
iconUnSelectAllRemoteRunDialog.gif Disable Selected Injections Click this icon to disable the injections that are currently selected in the list.
icon_injection_move_to_project_make_global.png Move to Project/IDE Scope
Shift+Space
Use this icon or shortcut to move the selected injections between the IDE and the project levels. See also, Scope.
iconImport.png Import Click this button to have an injection configuration from another WebStorm installation imported. The Select Path dialog opens, where you can select the IntelliLang.xml file from the desired location. The dialog box that opens displays the entries contained in the configuration file. Remove the unnecessary entries from the list using the Delete button.

Note

This will not affect the contents of the configuration file.

Tip

This selective import-feature makes it easy to share certain configurations in a team without losing any local entries as it happens when settings are imported via the core Importing Settings feature.

Warning

To prevent inconsistent data, import is only possible if the existing configuration has not been changed or has been saved using the Apply button.

exportToTextFile.png Export Click this button to have one or several selected injection configurations saved in a file. Upon clicking this button, the Export Selected Injections to File dialog box opens.
  • To have the configurations appended to an existing file, select the required file.
  • To have the configurations saved in a new file, specify the file name and choose the file type from the drop-down list.

See Also

Procedures:

Web Resources: