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

feat(tooling): Updating eslint and commitlint config. #435

Merged
merged 1 commit into from
Feb 23, 2024

Conversation

himerus
Copy link
Contributor

@himerus himerus commented Feb 23, 2024

Summary by CodeRabbit

  • Chores
    • Updated ESLint configuration to refine code quality checks, including adjustments to ignored files and directories, and enhancements in linting rules specifically for the project's needs.
    • Enhanced commit message quality by customizing the commitlint configuration to enforce more specific guidelines.

Copy link

changeset-bot bot commented Feb 23, 2024

⚠️ No Changeset found

Latest commit: 934ee19

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

coderabbitai bot commented Feb 23, 2024

Walkthrough

The recent updates involve refining the project's coding standards and commit message guidelines. Specifically, adjustments were made to the ESLint configuration to better handle project-specific needs, such as including new plugins and adjusting rules for improved code quality. Additionally, the commit message configuration was enhanced to allow for more tailored guidelines while adhering to conventional commit standards. These changes aim to streamline development workflows and maintain high code quality.

Changes

Files Change Summary
.eslintignore Updated to adjust included/excluded directories and file patterns, affecting .husky/, .turbo/, .vscode/, etc.
.eslintrc.json Removed @typescript-eslint/eslint-recommended, added lit plugin and es2021 env, updated rules and overrides.
commitlint.config.js Extended default configuration with project-specific customizations for commit messages.

Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit-tests for this file.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit tests for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository from git and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit tests.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • The JSON schema for the configuration file is available here.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/coderabbit-overrides.v2.json

CodeRabbit Discord Community

Join our Discord Community to get help, request features, and share feedback.

Copy link

netlify bot commented Feb 23, 2024

Deploy Preview for outlinejs ready!

Name Link
🔨 Latest commit 934ee19
🔍 Latest deploy log https://app.netlify.com/sites/outlinejs/deploys/65d8c1704058520008fa15ea
😎 Deploy Preview https://deploy-preview-435--outlinejs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

New and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher
npm/[email protected] Transitive: environment, eval, filesystem, shell, unsafe +95 13.8 MB 43081j

🚮 Removed packages: npm/[email protected]

View full report↗︎

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Review Status

Actionable comments generated: 1

Configuration used: CodeRabbit UI

Commits Files that changed from the base of the PR and between 8a08491 and 934ee19.
Files ignored due to path filters (2)
  • package.json is excluded by: !**/*.json
  • yarn.lock is excluded by: !**/*.lock
Files selected for processing (3)
  • .eslintignore (1 hunks)
  • .eslintrc.json (1 hunks)
  • commitlint.config.js (1 hunks)
Additional comments: 5
.eslintignore (1)
  • 4-7: Added directories .husky/, .turbo/, and .vscode/ to the ignore list. Ensure these directories do not contain any JavaScript files that should be linted. Ignoring .vscode/ might be unnecessary unless it contains project-specific scripts.
.eslintrc.json (3)
  • 8-16: The addition of the lit plugin and the es2021 environment setting are positive changes for projects using modern JavaScript features and Lit for web components. Ensure all project contributors are aware of these updates to avoid linting errors due to unfamiliarity with the new rules.
  • 25-26: Replacing lit-plugin/no-invalid-css with lit/no-invalid-html shifts the focus from CSS validation within Lit components to HTML validation. Verify that this change aligns with the project's priorities for component development and does not overlook the need for CSS validation.
  • 30-38: The updates to rule overrides for TypeScript and JavaScript files, such as disabling @typescript-eslint/explicit-module-boundary-types for .ts files and @typescript-eslint/no-var-requires for .js files, should be carefully considered. These changes may impact the strictness of type checking and the use of require in modules. Ensure these overrides align with the project's coding standards and practices.
commitlint.config.js (1)
  • 1-27: Extending the default commitlint configuration with project-specific alterations is a sound strategy for maintaining consistency in commit messages while allowing for customization. Ensure that any project-specific rules added are well-documented and communicated to all contributors to facilitate adherence.

.eslintignore Show resolved Hide resolved
@himerus himerus merged commit 5a49ef6 into next Feb 23, 2024
10 checks passed
@himerus himerus deleted the feature/lint-config-updates branch February 23, 2024 16:08
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.

1 participant