Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add cspell dictionary #11953

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Add cspell dictionary #11953

wants to merge 1 commit into from

Conversation

jjspace
Copy link
Contributor

@jjspace jjspace commented Apr 23, 2024

Description

These are some small repo changes that I've had locally for a little while and on't want to keep git-ignoring locally or stashing every PR

  1. Add Code spell checker as a workspace recommended extension
  2. Add .vscode/cspell.json to include a dictionary of words used in this project for the spell checker
  3. Add @ts-expect-error in CesiumSandcastle because it's using the "wrong" require function and if you have JS Type checking on it flags the entire file
    2024-04-23_11-52

Code Spell Checker

Code spell checker is really helpful when coding to make sure variable names and strings are spelled correctly. Longer term we may want to add cspell as a CI or pre-commit check but right now there's too many words that would be flagged as incorrect to justify that effort. To that end I do want to push people to use the extension more and collectively, gradually build up the dictionary until we're at a point there are very few flagged words and using the cli is more seemless.

When a word is flagged you just have to put the cursor on it and trigger the VSCode suggestion window Ctrl+. for me. Then just make sure you select the cspell.json file to make sure it's added to the repo's dictionary instead of your user or workspace settings.

2024-04-23_11-54
2024-04-23_11-54_1

@ggetz I know we discussed this and I think you have a list of words already in your user settings, feel free to copy those over and commit to this branch if you have a bunch to add intantly

Issue number and link

Part of #11954

Testing plan

Not much to test.
You can try turning on JS type checking for the sandcastle if you want, just be aware there are still lots of other TS errors we have in the library.
Add the extension if you don't already have it and flag a word and make sure you understand how to add words to our dictionary.

Author checklist

  • I have submitted a Contributor License Agreement
  • I have added my name to CONTRIBUTORS.md
  • I have updated CHANGES.md with a short summary of my change
  • I have added or updated unit tests to ensure consistent code coverage
  • I have update the inline documentation, and included code examples where relevant
  • I have performed a self-review of my code

@jjspace jjspace requested a review from ggetz April 23, 2024 16:03
Copy link

Thank you for the pull request, @jjspace!

✅ We can confirm we have a CLA on file for you.

@jjspace jjspace mentioned this pull request Apr 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant