Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/dtils/mod.unstable.ts>createWatcher

The best unofficial library of utilities for Deno applications
Go to Latest
function createWatcher
import { createWatcher } from "https://deno.land/x/dtils@2.6.0/mod.unstable.ts";

Create a watcher that monitors a list of files for updates

Example:

const watcher = createWatcher({
	onUpdate: (file) => console.log('File changed:', file)
})

watcher.addFiles(await recursiveReadDir('.'))