From 3664ed06605685c98d3302d56db92fc297ab8441 Mon Sep 17 00:00:00 2001 From: Adrian Bury Date: Fri, 19 Jul 2024 22:56:02 +0200 Subject: [PATCH] fix: unification copy behavior between watched and not watched assets `chokidar.watch` listen also for hidden files but `glob` do not this means hidden files are copied in watch mode but they are not when watch mode if turn off --- lib/compiler/assets-manager.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/compiler/assets-manager.ts b/lib/compiler/assets-manager.ts index c71bef10c..82760f27c 100644 --- a/lib/compiler/assets-manager.ts +++ b/lib/compiler/assets-manager.ts @@ -103,9 +103,10 @@ export class AssetsManager { this.watchers.push(watcher); } else { - const files = sync(item.glob, { ignore: item.exclude }).filter( - (matched) => statSync(matched).isFile(), - ); + const files = sync(item.glob, { + ignore: item.exclude, + dot: true, + }).filter((matched) => statSync(matched).isFile()); for (const path of files) { this.actionOnFile({ ...option, path, action: 'change' }); }