@bit-ocean/cspell

0.0.48 • Public • Published

@bit-ocean/cspell

npm

Universal CSpell dictionary configuration.

We use CSpell for code spell checking. This package provides some universal dictionaries for all our projects.

Installation

pnpm add -D cspell @bit-ocean/cspell

Configuration

Create a .cspell.json file in the root of your project and add the following:

{
  "$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/main/cspell.schema.json",
  "version": "0.2",
  "language": "en",
  "dictionaries": ["custom-words"],
  "dictionaryDefinitions": [
    {
      "name": "custom-words",
      "path": ".cspell.txt",
      "addWords": true
    }
  ],
  "import": ["@bit-ocean/cspell"]
}

Add cspell script to your package.json:

{
  "scripts": {
    "cspell:sort:dicts": "pnpm bo cspell:sort:dicts",
    "cspell:check": "cspell --no-progress --show-suggestion --show-context --cache **"
  }
}

License

MIT License © 2024 Bit Ocean

Package Sidebar

Install

npm i @bit-ocean/cspell

Weekly Downloads

3

Version

0.0.48

License

MIT

Unpacked Size

5.23 kB

Total Files

6

Last publish

Collaborators

  • zhiblcx
  • brucesong