feat: change css + watcher
Signed-off-by: Cédric OLIVIER <olivier.cedric@gmail.com>
This commit is contained in:
+4
-3
@@ -9,9 +9,10 @@ function startWatcher({ inputFile, inputDir, server }) {
|
||||
const watcher = chokidar.watch(watchTarget, {
|
||||
persistent: true,
|
||||
ignoreInitial: true,
|
||||
ignored: /(^|[/\\])\../, // ignore hidden files
|
||||
ignored: /(^|[/\\])\.\./, // ignore hidden files
|
||||
usePolling: true,
|
||||
interval: 500,
|
||||
interval: 300,
|
||||
awaitWriteFinish: { stabilityThreshold: 150, pollInterval: 50 },
|
||||
});
|
||||
|
||||
let debounceTimer = null;
|
||||
@@ -33,7 +34,7 @@ function startWatcher({ inputFile, inputDir, server }) {
|
||||
watcher.on('add', (filePath) => {
|
||||
if (!isDir || isMd(filePath)) {
|
||||
console.log(` + Nouveau fichier : ${path.basename(filePath)}`);
|
||||
schedule(filePath);
|
||||
schedule(null); // file list changed → full cache invalidation
|
||||
}
|
||||
});
|
||||
watcher.on('unlink', (filePath) => {
|
||||
|
||||
Reference in New Issue
Block a user