What is @cspell/dict-csharp?
@cspell/dict-csharp is a dictionary extension for the CSpell spell checker that provides a list of C#-specific terms. This package helps developers ensure that their C# code comments, documentation, and strings are free from spelling errors by recognizing C# terminology.
What are @cspell/dict-csharp's main functionalities?
C# Terminology Dictionary
This feature allows you to add a C# terminology dictionary to CSpell, enabling it to recognize and correctly spell-check C# specific terms. The code sample demonstrates how to integrate the C# dictionary with CSpell and check a piece of C# code for spelling errors.
const cspell = require('cspell');
const csharpDictionary = require('@cspell/dict-csharp');
cspell.addDictionary(csharpDictionary);
const text = 'public class MyClass { private int myField; }';
const options = { language: 'en', dictionaries: ['csharp'] };
cspell.checkText(text, options).then(result => {
console.log(result);
});
Other packages similar to @cspell/dict-csharp
@cspell/dict-python
@cspell/dict-python provides a dictionary of Python-specific terms for the CSpell spell checker. Similar to @cspell/dict-csharp, it helps ensure that Python code comments, documentation, and strings are free from spelling errors by recognizing Python terminology.
@cspell/dict-java
@cspell/dict-java offers a dictionary of Java-specific terms for the CSpell spell checker. It functions similarly to @cspell/dict-csharp by recognizing Java terminology and helping developers maintain spelling accuracy in their Java code comments and documentation.
CSpell csharp Dictionary
Csharp dictionary for cspell.
This is a pre-built dictionary for use with cspell.
Requirements
Installation
Global Install and add to cspell global settings.
npm install -g @cspell/dict-csharp
cspell link add @cspell/dict-csharp
Uninstall from cspell
cspell link remove @cspell/dict-csharp
Manual Installation
The cspell-ext.json
file in this package should be added to the import section in your cspell.json file.
{
"import": ["@cspell/dict-csharp/cspell-ext.json"],
}
Building
Building is only necessary if you want to modify the contents of the dictionary. Note: Building will take a few minutes for large files.
npm run build
License
MIT
Some packages may have other licenses included.