Interface: LanguageSetting
Defined in: CSpellSettingsDef.ts:634
Extends
Properties
allowCompoundWords?
optionalallowCompoundWords?:boolean
Defined in: CSpellSettingsDef.ts:503
True to enable compound word checking.
Default
false
Inherited from
BaseSetting.allowCompoundWords
caseSensitive?
optionalcaseSensitive?:boolean
Defined in: CSpellSettingsDef.ts:516
Determines if words must match case and accent rules.
See Case Sensitivity for more details.
false- Case is ignored and accents can be missing on the entire word. Incorrect accents or partially missing accents will be marked as incorrect.true- Case and accents are enforced.
Default
false
Inherited from
description?
optionaldescription?:string
Defined in: CSpellSettingsDef.ts:490
Optional description of configuration.
Inherited from
dictionaries?
optionaldictionaries?:string[]
Defined in: CSpellSettingsDef.ts:542
Optional list of dictionaries to use. Each entry should match the name of the dictionary.
To remove a dictionary from the list, add ! before the name.
For example, !typescript will turn off the dictionary with the name typescript.
See the Dictionaries and Custom Dictionaries for more details.
Inherited from
dictionaryDefinitions?
optionaldictionaryDefinitions?:DictionaryDefinition[]
Defined in: CSpellSettingsDef.ts:530
Define additional available dictionaries.
For example, you can use the following to add a custom dictionary:
"dictionaryDefinitions": [
{ "name": "custom-words", "path": "./custom-words.txt"}
],
"dictionaries": ["custom-words"]
Inherited from
BaseSetting.dictionaryDefinitions
enabled?
optionalenabled?:boolean
Defined in: CSpellSettingsDef.ts:496
Is the spell checker enabled.
Default
true
Inherited from
flagWords?
optionalflagWords?:string[]
Defined in: InlineDictionary.ts:34
List of words to always be considered incorrect. Words found in flagWords override words.
Format of flagWords
- single word entry -
word - with suggestions -
word:suggestionorword->suggestion, suggestions
Example:
"flagWords": [
"color: colour",
"incase: in case, encase",
"canot->cannot",
"cancelled->canceled"
]
Case Sensitivity:
A word is flagged if it exactly matches an entry, or if its lowercased form exactly matches an entry. In practice this means:
- An entry written in all lowercase (e.g.
avocado) flags that word in any casing found in the document —avocado,Avocado, andAVOCADOare all flagged. - An entry containing any uppercase letter (e.g.
Avocado) only flags that exact casing —avocadoandAVOCADOare not flagged.
Inherited from
id?
optionalid?:string
Defined in: CSpellSettingsDef.ts:484
Optional identifier.
Inherited from
ignoreRegExpList?
optionalignoreRegExpList?:RegExpPatternList
Defined in: CSpellSettingsDef.ts:582
List of regular expression patterns or pattern names to exclude from spell checking.
Example: ["href"] - to exclude html href pattern.
Regular expressions use JavaScript regular expression syntax.
Example: to ignore ALL-CAPS words
JSON
"ignoreRegExpList": ["/\\b[A-Z]+\\b/g"]
YAML
ignoreRegExpList:
- >-
/\b[A-Z]+\b/g
By default, several patterns are excluded. See Configuration for more details.
While you can create your own patterns, you can also leverage several patterns that are built-in to CSpell.
Inherited from
ignoreWords?
optionalignoreWords?:string[]
Defined in: InlineDictionary.ts:40
List of words to be ignored. An ignored word will not show up as an error, even if it is
also in the flagWords.
Inherited from
includeRegExpList?
optionalincludeRegExpList?:RegExpPatternList
Defined in: CSpellSettingsDef.ts:592
List of regular expression patterns or defined pattern names to match for spell checking.
If this property is defined, only text matching the included patterns will be checked.
While you can create your own patterns, you can also leverage several patterns that are built-in to CSpell.
Inherited from
languageId
languageId:
MatchingFileType
Defined in: CSpellSettingsDef.ts:641
The language id. Ex: typescript, html, or php. * -- will match all languages.
Inherited from
LanguageSettingFilterFields.languageId
local?
optionallocal?:string|string[]
Defined in: CSpellSettingsDef.ts:654
Deprecated - The locale filter, matches against the language. This can be a comma separated list. * will match all locales.
Deprecated
true
Inherited from
LanguageSettingFilterFields.local
locale?
optionallocale?:string|string[]
Defined in: CSpellSettingsDef.ts:643
The locale filter, matches against the language. This can be a comma separated list. * will match all locales.
Inherited from
LanguageSettingFilterFields.locale
name?
optionalname?:string
Defined in: CSpellSettingsDef.ts:487
Optional name of configuration.
Inherited from
noSuggestDictionaries?
optionalnoSuggestDictionaries?:string[]
Defined in: CSpellSettingsDef.ts:553
Optional list of dictionaries that will not be used for suggestions. Words in these dictionaries are considered correct, but will not be used when making spell correction suggestions.
Note: if a word is suggested by another dictionary, but found in one of these dictionaries, it will be removed from the set of possible suggestions.
Inherited from
BaseSetting.noSuggestDictionaries
parser?
optionalparser?:string
Defined in: CSpellSettingsDef.ts:914
Experimental
Parser to use for the file content
Since
6.2.0
Inherited from
patterns?
optionalpatterns?:RegExpPatternDefinition[]
Defined in: CSpellSettingsDef.ts:619
Defines a list of patterns that can be used with the ignoreRegExpList and includeRegExpList options.
For example:
"ignoreRegExpList": ["comments"],
"patterns": [
{
"name": "comment-single-line",
"pattern": "/#.*/g"
},
{
"name": "comment-multi-line",
"pattern": "/(?:\\/\\*[\\s\\S]*?\\*\\/)/g"
},
// You can also combine multiple named patterns into one single named pattern
{
"name": "comments",
"pattern": ["comment-single-line", "comment-multi-line"]
}
]
Inherited from
softWordBreakDefinitions?
optionalsoftWordBreakDefinitions?:SoftWordBreakDefinitions
Defined in: WordSegmentation.ts:25
Defines a set of word break rules that can be used for text segmentation.
Soft word breaks are done through injecting soft-hyphens at the appropriate positions in the text before spell checking.
This allows for word breaks that might not be captured by the camel case detection.
Note: soft-hyphens are removed before checking the word against the dictionaries.
For example, if there is a soft-hyphen (represented by a |) injected between error and code
error|code, the following words would be checked against
the dictionaries: errorcode, error, and code.
Since
10.3.1
Inherited from
BaseSetting.softWordBreakDefinitions
softWordBreaks?
optionalsoftWordBreaks?:SoftWordBreaks
Defined in: WordSegmentation.ts:32
Allows enabling or disabling soft word break rules by name.
Since
10.3.1
Inherited from
substitutionDefinitions?
optionalsubstitutionDefinitions?:SubstitutionDefinitions
Defined in: CSpellSettingsDef.ts:625
The set of available substitutions. This is a collection of substitution definitions that can be applied to a document before spell checking.
Since
9.7.0
Inherited from
BaseSetting.substitutionDefinitions
substitutions?
optionalsubstitutions?:Substitutions
Defined in: CSpellSettingsDef.ts:631
The set of substitutions to apply to a document before spell checking.
Since
9.7.0
Inherited from
suggestWords?
optionalsuggestWords?:string[]
Defined in: InlineDictionary.ts:55
A list of suggested replacements for words. Suggested words provide a way to make preferred suggestions on word replacements. To hint at a preferred change, but not to require it.
Format of suggestWords
- Single suggestion (possible auto fix)
word: suggestionword->suggestion
- Multiple suggestions (not auto fixable)
word: first, second, thirdword->first, second, third
Inherited from
unknownWords?
optionalunknownWords?:UnknownWordsChoices
Defined in: CSpellReporter.ts:333
Controls how unknown words are handled.
report-all- Report all unknown words (default behavior)report-simple- Report unknown words that have simple spelling errors, typos, and flagged words.report-common-typos- Report unknown words that are common typos and flagged words.report-flagged- Report unknown words that are flagged.
Default
"report-all"
Since
9.1.0
Inherited from
useIntlWordSegmentation?
optionaluseIntlWordSegmentation?:boolean
Defined in: WordSegmentation.ts:8
Enables locale-sensitive text segmentation to support languages like Japanese, Chinese, Thai, Lao, Khmer, Myanmar, etc. The locale used for the segmentation is based on the language setting.
Since
10.2.0
Inherited from
BaseSetting.useIntlWordSegmentation
words?
optionalwords?:string[]
Defined in: InlineDictionary.ts:5
List of words to be considered correct.