Skip to content

Conversation

@h-labushkina
Copy link

What:

Replace Chalk with Colorette;
fix to-have-style to use named red import

Why:
Security/supply-chain risk: Chalk has had ecosystem concerns and frequent transitive dependency changes. To reduce exposure, we removed Chalk and opted for a simpler library with fewer moving parts.
Size and performance: Chalk is feature-rich but heavier. Colorette is tiny, dependency-free, and fast. Switching trims our dependency tree and improves startup/formatting overhead in test runs.

How:

  • Removed malicious dependency chalk due to security concerns.
  • Switched to colorette and updated to-have-style to import red as a named export.
  • Adjusted expectedDiff to strip the “+ Received” annotation using red('+ Received'). ## Security:
  • Chalk removal mitigates risk from supply-chain compromise. Consider auditing the lockfile and running npm audit.

Checklist:

  • Documentation added to the docs
  • Typescript definitions updated
  • Tests
  • Ready to be merged

## Details:
- Removed malicious dependency chalk due to security concerns.
- Switched to colorette and updated to-have-style to import red as a named export.
- Adjusted expectedDiff to strip the “+ Received” annotation using red('+ Received').
## Security:
- Chalk removal mitigates risk from supply-chain compromise. Consider auditing the lockfile and running npm audit.
@mdjastrzebski
Copy link
Collaborator

This library is deprecated. Pls migrate to RN Testing Library built in matchers.

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.

2 participants