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.

@mrksbnc mrksbnc marked this pull request as ready for review January 8, 2026 19:05
@mrksbnc mrksbnc requested a review from Jason3S January 8, 2026 19:07
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 for the update.

Did you forget to add the fixtures and the eslint tests?

It would look like this: in src/test/index.test.mts

        readFix('issue-4870/sample.js', {
            cspell: {
                dictionaries: ['business-terms'],
                dictionaryDefinitions: [
                    {
                        name: 'business-terms',
                        path: fixtureRelativeToCwd('issue-4870/dictionaries/business-terminology.txt'),
                    },
                ],
            },
        }),

numSuggestions: 8,
generateSuggestions: true,
autoFix: false,
...defaultCheckOptions,
Copy link
Collaborator

Choose a reason for hiding this comment

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

What was the logic to move this after the explicit values?

I understand that the two should NOT overlap, but if they do, then the result might be unexpected to the person who added the value to defaultOptions because it will get overwritten by the ...defaultCheckOptions.

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