Live Preview: Build and Test Workers Faster with Wrangler CLI 1.2.0
Aug 20, 2019Matt Alonso

Summary
This post details the development of the `wrangler preview --watch` feature for the Cloudflare Workers CLI. The author implemented a file system watcher using the `notify` crate to detect changes and trigger builds. A cooldown period was introduced to prevent excessive builds. Communication with the previewer was achieved using WebSockets connected to localhost. The feature was released in Wrangler v1.2.0.