Skip to content

Conversation

@mrksbnc
Copy link
Collaborator

@mrksbnc mrksbnc commented Jan 1, 2026

This PR contains the changes required to resolve cspell ESLint plugin: support typos-only reporting (CLI --report typos / unknownWords report-common-typos) #8261

@mrksbnc mrksbnc self-assigned this Jan 1, 2026
@github-actions github-actions bot added the fix label Jan 1, 2026
@mrksbnc mrksbnc requested a review from Jason3S January 1, 2026 16:00
@Jason3S Jason3S changed the title refactor: unknown word report config change #8261 fix: unknown word report config change #8261 Jan 2, 2026
@Jason3S
Copy link
Collaborator

Jason3S commented Jan 4, 2026

@mrksbnc,

Need any more help?

Copy link
Collaborator

@Jason3S Jason3S left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We just need to add some tests:

We will need a fixture:
issue-8261

It can be added to test/index.test.mts. See issue-4870 as an example.

@mrksbnc mrksbnc added the task A task to be done. label Jan 4, 2026
Copy link
Collaborator

@Jason3S Jason3S left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you.

*
* default is 'all' unless overridden by CSpell settings
*/
report?: 'all' | 'simple' | 'typos' | 'flagged';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
report?: 'all' | 'simple' | 'typos' | 'flagged';
report?: 'all' | 'simple' | 'typos' | 'flagged' | undefined;

This is to support having the default be undefined.

import assert from 'node:assert';

import { spellCheck, type SpellCheckOptions } from './spellCheck.mjs';
import type { UnknownWordsChoices } from 'cspell-lib';
Copy link
Collaborator

@Jason3S Jason3S Jan 5, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for adding the unit tests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fix task A task to be done.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

cspell ESLint plugin: support typos-only reporting (CLI --report typos / unknownWords report-common-typos)

3 participants