Install via the CLI: code --install-extension stoplight.spectral
Extension Settings
This extension contributes the following settings:
spectral.enable: Controls whether or not Spectral is enabled.
spectral.rulesetFile: Location of the ruleset file to use when validating. If omitted, the default is a .spectral.(json|yaml|yml) in the same folder as the document being validated. Paths are relative to the workspace. This can also be a remote HTTP url.
spectral.run: Run the linter on save (onSave) or as you type (onType).
spectral.validateFiles: An array of file globs (e.g., **/*.yaml) which should be validated by Spectral. If language identifiers are also specified, the file must match both in order to be validated. You can also use negative file globs (e.g., !**/package.json) here to exclude files.
spectral.validateLanguages: An array of language IDs (e.g., yaml, json) which should be validated by Spectral. If file globs are also specified, the file must match both in order to be validated.