The vscode eslint extension says:
Configuration Options
eslint.enable
: enable/diable eslint. Is enabled by default.eslint.options
: an option bag as defined by the ESLint API here. Defaults to an empty option bag.
I cannot figure out where to configure the eslint extension? Searching configure
in the commands results in nothing.
There are two primary ways to configure ESLint: Configuration Comments - use JavaScript comments to embed configuration information directly into a file. Configuration Files - use a JavaScript, JSON, or YAML file to specify configuration information for an entire directory and all of its subdirectories.
You can add extension-level configuration in the VSCode settings.json
file. Open this through the command palette:
Add the rules in eslint.options
like this, according to the ESLint documentation:
// Place your settings in this file to overwrite the default settings { "eslint.options": { "rules": { "quotes": [2, "double"] } } }
You can add this to workspace-level configuration by opening "workspace settings" through the command palette. This will create a ./vscode/settings.json
file in your project.
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