The "Unused Test ID Remover" is a Visual Studio Code extension designed to help keep your React codebase clean and maintainable by automatically removing unused data-testid
attributes.
- Scan React Files: Automatically scans your React project for any unused
data-testid
attributes. - Clean and Maintainable Code: Helps maintain a cleaner codebase by removing unused test IDs that might accumulate over time.
- Simple to Use: Integrates seamlessly into your development workflow with a simple command within VS Code.
- Visual Studio Code version 1.84.0 or higher.
- This extension is designed for projects using React.
- Open Visual Studio Code.
- Navigate to the Extensions view by clicking on the square icon on the sidebar.
- Search for "Unused Test ID Remover".
- Click on the install button to install the extension.
To use the extension, follow these steps:
- Open your React project in Visual Studio Code.
- Open the Command Palette (
Ctrl+Shift+P
on Windows/Linux,Cmd+Shift+P
on macOS). - Type "remove unused test ids" and select the command.
- The extension will scan your project and remove any unused
data-testid
attributes.
This extension contributes the following command:
unused-test-id-remover.removeUnusedTestIds
: Scans the current project and removes any unuseddata-testid
attributes.
Contributions to the extension are welcome. Please ensure to follow the coding style and add tests for any new features or bug fixes.
This project is licensed under the MIT License.