chokidar
6.0.0 · 19 Oct 2026MIT124.9M / weekRepositorynpmAtom feed
105 stable releases, newest first, by release line. Notes are quoted as the maintainers published them.
- 6.x · latest line
6.0.0
19 Oct 2026Rewrote the watcher around a single observation pipeline. Backend callbacks are treated as invalidations and confirmed with
lstat,stat, orreaddirbefore any event is emitted, so the final state after a burst of changes matches the filesystem.Added native recursive watching through
fs.watch({ recursive: true }). The defaultautobackend uses it on macOS and Windows and per-directory watching elsewhere.
High-level changes
Rewrote the watcher around a single observation pipeline. Backend callbacks are treated as invalidations and confirmed with
lstat,stat, orreaddirbefore any event is emitted, so the final state after a burst of changes matches the filesystem.Added native recursive watching through
fs.watch({ recursive: true }). The defaultautobackend uses it on macOS and Windows and per-directory watching elsewhere.Shared native handles across watchers and opened them per directory only: files no longer own handles. This fixes
EBADFerrors when watching many files on macOS (#1385, #1452).Replaced
fs.watchFilewith Chokidar-owned stat polling. Poll loops are shared across watchers at the fastest requested interval.Required Node.js 22.22 or later.
API changes
Added the
backendoption:'auto'(default),'native','native-recursive', or'polling'.usePolling: trueremains as a deprecated alias forbackend: 'polling'.
Renamed
intervalandbinaryIntervaltopollingIntervalandpollingBinaryInterval.The old names remain as deprecated aliases; the new names win when both are given.
Changed the
atomicdefault tofalsewith polling. An explicit value is preserved.Made
close()terminal:add()now throws once closing has started. Construct a new watcher instead.Validated options in the constructor: invalid
backend,atomic,depth,awaitWriteFinish, and polling intervals throwTypeError.Emitted errors from
add()aserrorevents instead of unhandled rejections (#1378).Made
getWatched()return a null-prototype object, so a watched directory named__proto__is listed (#1493). UseObject.hasOwn()instead ofhasOwnProperty()on the result.Stopped applying
ignoredto directories above a path passed towatch()oradd(), so a missing path is still watched through its parent (#1374). Other entries in those directories are still filtered.
Fixes
Fixed a 100% CPU loop when the process working directory containing a relatively watched file was deleted (#1474).
Fixed watching a filesystem root, which emitted
unlinkandunlinkDirfor every entry (#1184, #452).Fixed
UNKNOWNerrors fromfs.watchon macOS sockets, which prevented watching/var/run(#1391).Fixed a symlink whose target passes through a regular file (
ENOTDIR) disabling watching of its directory and preventingready(#1476).Fixed files created in a newly added directory between its scan and watch registration being missed (#1471).
Fixed watching a missing nested path stopping its parent directory's subtree from being watched (#1470).
Fixed false
changeevents on Windows when many sibling files are written (#1466).Fixed duplicate
addevents for unchanged files under directory activity (#1465).Fixed replacing a watched directory with a file of the same name hanging the process (#1464).
Fixed persistent watching stopping after a watched directory was removed (#1463).
Fixed a deleted watched path not being reported when recreated: previously only a deleted file that was the sole watched path was watched for its return. Any path passed to
watch()oradd()is now awaited from its nearest existing parent.Fixed event throttling discarding updates; the newest differing change is now replayed when the window closes (#1455).
Fixed relative
ignoredpaths; relative strings now resolve againstcwdor the process working directory (#1436).Fixed files not being detected when their directory did not exist before watching (#1422).
Fixed removed files being reported as
unlinkDirinstead ofunlink(#1421).Fixed ignored files and directories still being watched in WSL (#1418).
Fixed
changebeing reported for every file when one file changed under Deno (#1417).Fixed changes not being detected after the second save (#1399).
Fixed renaming a watched directory that contains subdirectories on Windows (#1380, #1398).
Fixed re-watching a path not honoring
ignoreInitial(#1386).Fixed
EISDIRerrors during the initial scan of network drives (#1376).Fixed watching an array of absolute file paths (#1366).
Fixed unwatching a deleted watched directory on Windows, contributed
Documented that unwatched paths stay ignored until they are added again (#1439).
Misc
Made the
Statsimport type-only, contributedPinned dev dependencies and restricted workflow permissions, contributed
- 5.x
5.0.0
25 Nov 2025Reading the note…
- 4.x
4.0.3
18 Dec 2024Reading the note…
4.0.2
16 Dec 2024Reading the note…
4.0.1
22 Sep 2024Reading the note…
4.0.0
13 Sep 2024Reading the note…
- 3.x
3.6.0
6 Feb 2024Reading the note…
3.5.3
18 Jan 2022Reading the note…
3.5.2
15 Jun 2021Reading the note…
3.5.1
15 Jan 2021Reading the note…
3.5.0
6 Jan 2021Reading the note…
3.4.3
13 Oct 2020Reading the note…
3.4.2
6 Aug 2020Reading the note…
3.4.1
16 Jul 2020Reading the note…
3.4.0
26 Apr 2020Reading the note…
3.3.1
15 Dec 2019Reading the note…
3.3.0
2 Nov 2019Reading the note…
3.2.3
28 Oct 2019Reading the note…
3.2.2
16 Oct 2019Reading the note…
3.2.1
1 Oct 2019Reading the note…
3.2.0
1 Oct 2019Reading the note…
3.1.1
19 Sep 2019Reading the note…
3.1.0
16 Sep 2019Reading the note…
3.0.2
7 Jul 2019Reading the note…
3.0.1
2 Jun 2019Reading the note…
3.0.0
30 Apr 2019Reading the note…
- 2.x
2.1.8
21 Aug 2019Reading the note…
2.1.7
21 Aug 2019Reading the note…
2.1.6
15 May 2019Reading the note…
2.1.5
22 Mar 2019Reading the note…
2.1.4
22 Mar 2019Reading the note…
2.1.3
22 Mar 2019Reading the note…
2.1.2
18 Feb 2019Reading the note…
2.1.1
11 Feb 2019Reading the note…
2.1.0
5 Feb 2019Reading the note…
2.0.4
18 Jun 2018Reading the note…
2.0.3
23 Mar 2018Reading the note…
2.0.2
14 Feb 2018Reading the note…
2.0.1
8 Feb 2018Reading the note…
2.0.0
29 Dec 2017Reading the note…
- 1.x
1.7.0
8 May 2017Reading the note…
1.6.1
14 Oct 2016Reading the note…
1.6.0
22 Jun 2016Reading the note…
1.5.2
7 Jun 2016Reading the note…
1.5.1
20 May 2016Reading the note…
1.5.0
10 May 2016Reading the note…
1.4.3
27 Feb 2016Reading the note…
1.4.2
30 Dec 2015Reading the note…
1.4.1
9 Dec 2015Reading the note…
1.4.0
3 Dec 2015Reading the note…