Rider Help

ESLint

File | Settings | Languages and Frameworks | JavaScript | Code Quality Tools | ESLint for Windows and Linux
Rider | Preferences | Languages and Frameworks | JavaScript | Code Quality Tools | ESLint for macOS
Ctrl+Alt+S /help/img/rider/2017.1/settings.png


Use this page to enable the JavaScript ESLint code verifier and to configure its behaviour. If you are using JavaScript Standard Style in your project, you can enable linting with it here.

To configure Rider code style options for JavaScript to follow the main rules Standard declares so they are applied when you type the code or reformat it, open the Code Style. JavaScript page (File | Settings | Editor | Code Style | JavaScript for Windows and Linux or Rider | Preferences | Editor | Code Style | JavaScript for macOS), click Set from, and then choose Predefined Style | JavaScript Standard Style. The style will replace your current scheme.

ItemDescription
Enable Select this check box to have ESLint/Standard applied to verify the code in the current project. After that the other controls in the page are enabled.
Node Interpreter In this field, specify the Node.js interpreter to use. Choose one of the configured interpreters or click browseButton.png and configure a new one as described in Configuring Node.js Interpreters.

If you have appointed one of the installations as default, the field displays the path to its executable file.

ESLint Package In this field, specify the location of the eslint or standard package.
Configuration file In this area, appoint the configuration to use.

By default, Rider first looks for a .eslintrc in the folder with the file to be checked, then in its parent folder, and so on up to the project root. If no .eslintrc is found, ESLint uses its default embedded configuration file. Accordingly, either define the configuration to use (in .eslintrc or in a custom JSON configuration file) or rely on the default embedded configuration.

  • To have Rider look for a .eslintrc file, choose the Search for.eslintrc option. If no .eslintrc file is found, the default embedded configuration file will be used.
  • To use a custom file, choose the Configuration File option and specify the location fo the file in the Path field. Choose the path from the drop-down list, or type it manually, or click the /help/img/idea/2017.2/browseButton.png button and select the relevant file from the dialog box that opens.
Additional Rules Directory In this field, specify the location of the files with additional code verification rules. These rules will be applied after the rules from .eslintrc or the above specified custom configuration file and accordingly will override them.
Extra ESLint Options In this field, specify additional command line options to run ESLint with using spaces as separators. See ESLint Command Line Interface Options for details.
Last modified: 11 October 2017

See Also