Files, Folders, and Workspaces
Settings that control which files and folders are spell checked.
Setting | Scope | Description |
---|---|---|
cSpell.checkOnlyEnabledFileTypes | resource | Check Only Enabled File Types |
cSpell.enabledFileTypes | resource | Enabled File Types to Check |
cSpell.enabledSchemes | window | Specify Allowed Schemes |
cSpell.files | resource | Glob patterns of files to be checked. Glob patterns are relative to the #cSpell.globRoot# … |
cSpell.globRoot | resource | The root to use for glob patterns found in this configuration. Default: The current workspace… |
cSpell.ignorePaths | resource | Glob patterns of files to be ignored |
cSpell.import | resource | Allows this configuration to inherit configuration for one or more other files. |
cSpell.mergeCSpellSettings | resource | Specify if fields from .vscode/settings.json are passed to the spell checker. This only applies… |
cSpell.mergeCSpellSettingsFields | resource | Specify which fields from .vscode/settings.json are passed to the spell checker. This only… |
cSpell.noConfigSearch | resource | Prevents searching for local configuration when checking individual documents. |
cSpell.spellCheckOnlyWorkspaceFiles | window | Spell Check Only Workspace Files |
cSpell.useGitignore | resource | Tells the spell checker to load .gitignore files and skip files that match the globs in the… |
cSpell.usePnP | resource | Packages managers like Yarn 2 use a .pnp.cjs file to assist in loading packages stored in… |
cSpell.workspaceRootPath | resource | Workspace Root Folder Path |
Settings
cSpell.checkOnlyEnabledFileTypes
Name
cSpell.checkOnlyEnabledFileTypes
-- Check Only Enabled File TypesDescription
By default, the spell checker checks only enabled file types. Use
cSpell.enableFiletypes
to turn on / off various file types.When this setting is
false
, all file types are checked except for the ones disabled bycSpell.enabledFileTypes
. SeecSpell.enableFiletypes
on how to disable a file type.Type
boolean
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
true
cSpell.enabledFileTypes
Name
cSpell.enabledFileTypes
-- Enabled File Types to CheckDescription
Enable / Disable checking file types (languageIds).
This setting replaces:
cSpell.enabledLanguageIds
andcSpell.enableFiletypes
.A Value of:
true
- enable checking for the file typefalse
- disable checking for the file type
A file type of
*
is a wildcard that enables all file types.Example: enable all file types
File Type Enabled Comment *
true
Enable all file types. json
false
Disable checking for json files. Type
object
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
{"*":true,"markdown":true}
cSpell.enabledSchemes
Name
cSpell.enabledSchemes
-- Specify Allowed SchemesDescription
Control which file schemes will be checked for spelling (VS Code must be restarted for this setting to take effect).
Some schemes have special meaning like:
untitled
- Used for new documents that have not yet been savedvscode-notebook-cell
- Used for validating segments of a Notebook.vscode-userdata
- Needed to spell check.code-snippets
vscode-scm
- Needed to spell check Source Control commit messages.comment
- Used for new comment editors.
Type
object
Scope
window - Windows (instance) specific settings which can be configured in user, workspace, or remote settings.
Default
{
"comment": true, "file": true, "gist": true, "repo": true, "sftp": true,
"untitled": true, "vscode-notebook-cell": true, "vscode-scm": true,
"vscode-userdata": true, "vscode-vfs": true, "vsls": true
}
cSpell.files
Name
cSpell.files
Description
Glob patterns of files to be checked. Glob patterns are relative to the
cSpell.globRoot
of the configuration file that defines them.Type
string[]
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
- none -
cSpell.globRoot
Name
cSpell.globRoot
Description
The root to use for glob patterns found in this configuration. Default: The current workspace folder. Use
globRoot
to define a different location.globRoot
can be relative to the location of this configuration file. Defining globRoot, does not impact imported configurations.Special Values:
${workspaceFolder}
- Default - globs will be relative to the current workspace folder${workspaceFolder:<name>}
- Where<name>
is the name of the workspace folder.
Type
string
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
- none -
cSpell.ignorePaths
Name
cSpell.ignorePaths
-- Glob patterns of files to be ignoredDescription
Glob patterns of files to be ignored. The patterns are relative to the
cSpell.globRoot
of the configuration file that defines them.Type
string[]
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
[
"package-lock.json", "node_modules", "vscode-extension",
".git/{info,lfs,logs,refs,objects}/**", ".git/{index,*refs,*HEAD}", ".vscode",
".vscode-insiders"
]
cSpell.import
Name
cSpell.import
Description
Allows this configuration to inherit configuration for one or more other files.
See Importing / Extending Configuration for more details.
Type
string[]
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
- none -
cSpell.mergeCSpellSettings
Name
cSpell.mergeCSpellSettings
Description
Specify if fields from
.vscode/settings.json
are passed to the spell checker. This only applies when there is a CSpell configuration file in the workspace.The purpose of this setting to help provide a consistent result compared to the CSpell spell checker command line tool.
Values:
true
- all settings will be merged based uponcSpell.mergeCSpellSettingsFields
.false
- only use.vscode/settings.json
if a CSpell configuration is not found.
Note: this setting is used in conjunction with
cSpell.mergeCSpellSettingsFields
.Type
boolean
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
true
Since Version
4.0.0
cSpell.mergeCSpellSettingsFields
Name
cSpell.mergeCSpellSettingsFields
Description
Specify which fields from
.vscode/settings.json
are passed to the spell checker. This only applies when there is a CSpell configuration file in the workspace andcSpell.mergeCSpellSettings
istrue
.Values:
{ flagWords: true, userWords: false }
- Always allowflagWords
, but never allowuserWords
.
Example:
"cSpell.mergeCSpellSettingsFields": { "userWords": false }
Type
object
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
{
"allowCompoundWords": true, "caseSensitive": true, "dictionaries": true,
"dictionaryDefinitions": true, "enableGlobDot": true, "features": true,
"files": true, "flagWords": true, "gitignoreRoot": true, "globRoot": true,
"ignorePaths": true, "ignoreRegExpList": true, "ignoreWords": true, "import":
true, "includeRegExpList": true, "language": true, "languageId": true,
"languageSettings": true, "loadDefaultConfiguration": true, "minWordLength":
true, "noConfigSearch": true, "noSuggestDictionaries": true, "numSuggestions":
true, "overrides": true, "patterns": true, "pnpFiles": true, "reporters": true,
"suggestWords": true, "useGitignore": true, "usePnP": true, "userWords": true,
"validateDirectives": true, "words": true
}Since Version
4.0.0
cSpell.noConfigSearch
Name
cSpell.noConfigSearch
Description
Prevents searching for local configuration when checking individual documents.
Type
boolean
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
- none -
cSpell.spellCheckOnlyWorkspaceFiles
Name
cSpell.spellCheckOnlyWorkspaceFiles
-- Spell Check Only Workspace FilesDescription
Only spell check files that are in the currently open workspace. This same effect can be achieved using the
cSpell.files
setting."cSpell.files": ["/**"]
Type
boolean
Scope
window - Windows (instance) specific settings which can be configured in user, workspace, or remote settings.
Default
false
cSpell.useGitignore
Name
cSpell.useGitignore
Description
Tells the spell checker to load
.gitignore
files and skip files that match the globs in the.gitignore
files found.Type
boolean
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
true
cSpell.usePnP
Name
cSpell.usePnP
Description
Packages managers like Yarn 2 use a
.pnp.cjs
file to assist in loading packages stored in the repository.When true, the spell checker will search up the directory structure for the existence of a PnP file and load it.
Type
boolean
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
- none -
cSpell.workspaceRootPath
Name
cSpell.workspaceRootPath
-- Workspace Root Folder PathDescription
Define the path to the workspace root folder in a multi-root workspace. By default it is the first folder.
This is used to find the
cspell.json
file for the workspace.Example: use the
client
folder${workspaceFolder:client}
Type
string
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Default
- none -
cSpell.allowedSchemas
cSpell.allowedSchemas
Name
-- Define Allowed SchemescSpell.allowedSchemas
Description
Control which file schemes will be checked for spelling (VS Code must be restarted for this setting to take effect).
Some schemes have special meaning like:
untitled
- Used for new documents that have not yet been savedvscode-notebook-cell
- Used for validating segments of a Notebook.vscode-userdata
- Needed to spell check.code-snippets
vscode-scm
- Needed to spell check Source Control commit messages.comment
- Used for new comment editors.
Type
string[]
Scope
window - Windows (instance) specific settings which can be configured in user, workspace, or remote settings.
Deprecation Message
- Use
#cSpell.enabledSchemes#
instead.
- Use
Default
- none -
cSpell.enableFiletypes
cSpell.enableFiletypes
Name
-- Enable File TypescSpell.enableFiletypes
Description
Enable / Disable checking file types (languageIds).
These are in additional to the file types specified by
cSpell.enabledLanguageIds
. To disable a language, prefix with!
as in!json
,Example: individual file types
jsonc // enable checking for jsonc
!json // disable checking for json
kotlin // enable checking for kotlinExample: enable all file types
* // enable checking for all file types
!json // except for jsonType
string[]
Scope
resource - Resource settings, which apply to files and folders, and can be configured in all settings levels, even folder settings.
Deprecation Message
- Use
#cSpell.enabledFileTypes#
instead.
- Use
Default
- none -