From b1b7884d4b9af734773c178ab4377e55a5bb2cc6 Mon Sep 17 00:00:00 2001 From: Aram Drevekenin Date: Tue, 24 Dec 2019 16:23:43 +0100 Subject: [PATCH] fix(watch): trigger change event for creation/deletion of children in a folder --- src/volume.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/volume.ts b/src/volume.ts index 2fd63950..6474e5bc 100644 --- a/src/volume.ts +++ b/src/volume.ts @@ -2563,6 +2563,9 @@ export class FSWatcher extends EventEmitter { this._link.getNode().on('change', this._onNodeChange); + this._link.on('child:add', this._onNodeChange); + this._link.on('child:delete', this._onNodeChange); + const parent = this._link.parent; if (parent) { // parent.on('child:add', this._onParentChild);