Skip to content

Spelling Plugin

Rules that detect misspelling typos in source files using the code-optimized "CSpell" spell-checker.
This plugin is provided in a standalone @flint.fyi/plugin-spelling npm package.

Terminal window
npm install @flint.fyi/plugin-spelling

See the CSpell spell checker documentation for more details on spell-checking code.

Rules that run CSpell to find likely spell-checking mistakes.

flint.config.ts
import {
function defineConfig(definition: ConfigDefinition): Config

Defines a new linter configuration for a Flint config file.

@seehttps://flint.fyi/configuration flint.fyi/configuration

defineConfig
,
const globs: {
all: FilesComputer;
}
globs
,
import spelling
spelling
} from "flint";
export default
function defineConfig(definition: ConfigDefinition): Config

Defines a new linter configuration for a Flint config file.

@seehttps://flint.fyi/configuration flint.fyi/configuration

defineConfig
({
ConfigDefinition.use: ConfigUseDefinition[]

Specifies the files to be linted alongside the rules and settings to lint with.

@seehttps://flint.fyi/configuration#use flint.fyi/configuration#use

use
: [
{
ConfigUseDefinition.files: AnyLevelDeep<FilesValue>

A list of glob patterns describing which file(s) to lint.

@seehttps://flint.fyi/configuration#files flint.fyi/configuration#files

files
:
const globs: {
all: FilesComputer;
}
globs
.
all: FilesComputer

Selects all files included (and not excluded) by past config definitions.

all
,
ConfigUseDefinition.rules: AnyLevelDeep<ConfigRuleDefinition>

Any number of rules and/or presets of rules to enable for those files.

@seehttps://flint.fyi/configuration#rules flint.fyi/configuration#rules

rules
:
import spelling
spelling
.
any
presets
.
any
logical
,
},
],
});
Flint RulePreset
cspellRuns the CSpell spell checker on any source code file.logical
Made with ❤️‍🔥 around the world by the Flint team and contributors.