Add ``path`` to watch for autoreload.

def watch_dir(path: str) -> None:
    """Add ``path`` to watch for autoreload."""
    _compile_exclude_patterns()
    if config.autoreload or config.debug:
        # Add files to watch for autoreload
        p = pathlib.Path(path)
        p.resolve()
        _add_watch_path(p)