Skip to content

Commit 3206ab0

Browse files
author
User
committed
fix: watcher now accounts for additionalInclude patterns
- Merge additionalInclude patterns with include patterns in handleChange - Ensures files matching additionalInclude patterns are watched for changes - Addresses PR review feedback from repository author
1 parent 8409030 commit 3206ab0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/watcher/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,11 +75,12 @@ export class FileWatcher {
7575
}
7676

7777
private handleChange(type: FileChangeType, filePath: string): void {
78+
const includePatterns = [...this.config.include, ...(this.config.additionalInclude ?? [])];
7879
if (
7980
!shouldIncludeFile(
8081
filePath,
8182
this.projectRoot,
82-
this.config.include,
83+
includePatterns,
8384
this.config.exclude,
8485
createIgnoreFilter(this.projectRoot)
8586
)

0 commit comments

Comments
 (0)