Error Detector is a Visual Studio Code extension that helps you scan and identify specific pattern rules (such as TODO, FIXME, debugger, and console.log) in your code. It provides real-time diagnostics, a status bar summary, and convenient Quick Fix actions to clean up your files.
Features
- Real-time Scan: Scans active text documents for custom patterns on open and file edit (debounced).
- Status Bar Integration: Displays a clean status indicator showing the number of errors and warnings in the active document.
- Quick Fixes: Quickly resolve issues directly from the lightbulb menu (e.g., automatically remove or comment out the match).
- Customizable Rules: Custom regex patterns, flags, diagnostic messages, and severity levels can be defined in user settings.
- Exclusion Filters: Exclude specific files and directories (like
node_modulesor build outputs) from being scanned.
Extension Settings
This extension contributes the following settings:
error-detector.enable: Enable or disable the Error Detector extension.error-detector.patterns: A list of patterns to match. Each pattern has a regular expression, severity level, message, and regex flags.error-detector.exclude: Glob patterns specifying files and folders to exclude from scanning.
Usage
- Open any file in VS Code.
- The status bar will show the summary of issues.
- Hover over highlighted items to see details, and use
Ctrl+.(or click the lightbulb icon) to trigger Quick Fixes.