Setup Code Quality Tools (Formatting & Linting) #62
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request introduces several enhancements to our code quality and linting processes. The changes include setting up GitHub Actions for code quality checks, configuring ESLint, Prettier, and Stylelint, and adding relevant dependencies and configurations.
This pull request does not yet include the formatting and linting fixes for existing code. I intend to submit these code changes in a separate pull request after this pull request is merged.
Enhancements to code quality checks:
.github/workflows/code-quality.yml: Added a GitHub Actions workflow to run the new code quality checks on push and pull request events.Linting and formatting configurations:
eslint.config.mjs: Configured ESLint with various plugins and rules for TypeScript, React, and Docusaurus to ensure best practices.prettier.config.mjs: Added a Prettier configuration file with a plugin for JSDoc.stylelint.config.mjs: Added a Stylelint configuration file extending the standard configuration.Pre-commit hooks and lint-staged setup:
.husky/pre-commit: Addedlint-stagedto run linters on staged files before committing.lint-staged.config.mjs: Configuredlint-stagedto run ESLint, Stylelint, and Prettier on relevant files.Dependency updates:
package.json: Added dependencies for ESLint, Prettier, Stylelint, and Husky, and updated scripts to include linting and formatting commands.Additionally:
*.mdfiles and.githubdirectory to prevent conflicts with Remark Lint and maintain GitHub-specific configurations.@types/reactdependency to ensure proper TypeScript definitions for React components.