Skip to content

Conversation

@davidfirst
Copy link
Member

When bit check-types runs without finding any components (e.g., all are exported), it now shows a helpful message similar to other commands like bit test:

no components found to check.
use "--unmodified" flag to check all components or specify the ids to check.
otherwise, only new and modified components will be checked

Also added the component count to the success message for better feedback.

Copilot AI review requested due to automatic review settings January 9, 2026 20:33
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR enhances the bit check-types command to provide better user feedback when no components are found to check. It aligns the behavior with similar commands like bit test and bit build by showing an informative message that explains why no components were checked and how to check all components. Additionally, it adds component count information to the success message.

Key Changes:

  • Added handling for empty component lists with helpful guidance message
  • Enhanced success message to include the count of checked components
  • Modified runDiagnosticOnTsServer to return both tsserver instance and component count

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@davidfirst
Copy link
Member Author

Addressing Copilot review comments:

  1. Type safety for null return: Fixed by using undefined instead of null, which matches the return type of getTsserverClient() (TsserverClient | undefined).

  2. Pluralization: Keeping the component(s) format for consistency with other commands in the codebase.

@davidfirst davidfirst merged commit b84a830 into master Jan 12, 2026
12 checks passed
@davidfirst davidfirst deleted the fix/check-types-no-components-message branch January 12, 2026 15:34
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.

3 participants