Questions tagged [chokidar]

Node.js library for the cross-platform files watching. Used by gulp, browser-sync and webpack.

Node.js library for the cross-platform files watching. Used by gulp, browser-sync and webpack.

81 questions
1
vote
1 answer

The same pattern works with chokidar-cli but does not work with chokidar on windows

Hello I'm trying to setup chokidar on Windows. I got to work it with chokidar-cli, this is the command line that reports the events correctly: chokidar "D:\PATH\**\WATCHED_FOLDER\*.TXT" But when I try to do the same thing with node index.js, with…
Lorenz Meyer
  • 19,166
  • 22
  • 75
  • 121
0
votes
0 answers

How to Handle Rename Event in npm Chokidar

When I renamed a file/folder in windows where chokidar is watching Parent Directory, then Add and unlink events are getting triggered which is not expected. So help me on this how to handle the Rename of Folder or File preventing the** add and…
0
votes
0 answers

Module not found: Error: Can't resolve 'fsevents' in '..\chokidar\lib'

I'm a beginner. Please help me with the following error: WARNING in ./node_modules/glob-watcher/node_modules/chokidar/lib/fsevents-handler.js 7:17-36 Module not found: Error: Can't resolve 'fsevents' in…
0
votes
0 answers

Can Vite watch additionalData files defined in vite.config.js?

I'm using SvelteJS with the following vite.config.js: import { sveltekit } from '@sveltejs/kit/vite'; import { defineConfig } from 'vitest/config'; export default defineConfig({ plugins: [sveltekit()], test: { include:…
Jake Wilson
  • 88,616
  • 93
  • 252
  • 370
0
votes
0 answers

How to watch local directory changes in Nextjs

I would like to get the name of each folder that is added to a certain folder. I tried chokidar but I didn't make it working. so I searched for an equivalent and I didn't find anything... I want to choose a local folder and each time there's a new…
surex
  • 1
  • 1
0
votes
0 answers

PhpStorm: after update to 2022.3.1 npm watcher failed

After PhpStorm update to 2022.3.1 the npm watcher fails. If I start from terminal inside PhpStorm (version 2022.3.1), the following error is thrown: ... Error: ENOSPC: System limit for number of file watchers reached, watch…
rammi22
  • 271
  • 1
  • 11
0
votes
0 answers

Accessing a nodejs websocket connection object outside it's declaration

I've created a single-page system and disk status node app dashboard in javascript using the Chokidar package in the server to watch for system and disk status file updates placed into a "new" directory from other enterprise applications. The…
0
votes
1 answer

how can i install react native on window command?

i tried to install 'npm install --global expo-cli' and i get this error. svgo@1.3.2 this svgo is no longer supported. upgrade to v2.x.x, uuid@3.4.0 please upgrade to version 7 or higher, chokidar@2.1.8: chokidar 2 does not receive security update…
Yero
  • 3
  • 2
0
votes
1 answer

Watching a folder with Chokidar outside of application with docker

I have a application that watches for changes made in a folder, but I want to be able to change which folder is being watched in the users local system. If possible, a file path would be able to be pasted in the docker-compose file, and the…
CodeNoob
  • 25
  • 1
  • 8
0
votes
1 answer

Massive memory/RAM usage with Chokidar Node.js package from pre-existing files in directory being watched unnecessarily

I'm using the Node.js package "chokidar" for this use case: I'm just watching a single directory on Linux, not recursively I only need it to watch for add events, for when files are atomically moved into the watched directory (they're moved from…
LaVache
  • 2,372
  • 3
  • 24
  • 38
0
votes
1 answer

copyFile with node occasionally only copies part of file

I'm trying to build a file watcher that copies files when they are finally added using chokidar. The files have differing sizes, but range between 200MB and 1GB. watch(`${inputFolder}/*/**`, { ignoreInitial: false, awaitWriteFinish:…
prohit
  • 609
  • 1
  • 6
  • 18
0
votes
1 answer

Why am I getting this error - Failed to compile. Can't resolve 'modules/App' and "Error from chokidar (E:\): Error: EBUSY: resource busy or locked"?

My react js application was running fine till today, and suddenly a strange error started showing up when try to start my application. Failed to compile. ./src/index.js Module not found: Can't resolve 'modules/App' in…
Sri
  • 568
  • 1
  • 6
  • 18
0
votes
0 answers

Push fs / chokidar data to array

I was using chokidar for the first time and I was trying to get all the file names in a directory and push them to an array. Chokidar successfully gets the file names but when I push them to array the names are not being registered. Or maybe they…
seriously
  • 1,202
  • 5
  • 23
0
votes
1 answer

NPM Audit Error -- Regular expression denial of service

<-----CLOSED SOLVED ----> I am learning how to use Angulur. I am getting 5 moderate errors that I could not solve inside of a project folder. I had spent 2 all days on it without a success. I hope one of you could tell me how to remedy this. I…
Karen
  • 23
  • 2
0
votes
0 answers

NodeJS Chokidar / fs issues with cloud object storage volumes mapped to docker container

I am using Chokidar package in my NodeJS code and having issues with watching folders that are created in Cloud Object Storage bucket and mounted as volumes in my Runtime. Same code is working flawlessly in my local Mac and also in on-prem linux…
JavaNaresh
  • 5
  • 1
  • 1
  • 4