kentaro-m/coverage-markers

View on GitHub
lib/utils.js

Summary

Maintainability
A
0 mins
Test Coverage
import chokidar from 'chokidar';

export default function createWatcher(coverageFilePath) {
  const options = {
    awaitWriteFinish: {
      stabilityThreshold: 1000,
      pollInterval: 100,
    },
  };

  const watcher = chokidar.watch(coverageFilePath, options);

  return watcher;
}