Skip to content

Add method to convert paths to globs #240

@sindresorhus

Description

@sindresorhus

The change in 3.0.0 that changed it to only allow forward slash paths turned out to be a pain. Anywhere I use fast-glob, I now need to specially normalize paths on Windows.

Would be useful if fast-glob had a .convertToGlob() kinda method, with similar logic to sindresorhus/del@01da91f#diff-168726dbe96b3ce427e7fedce31bb0bcR41-R53.

Maybe there could even be some kind of option to loosen fast-glob, when you don't need glob escaping, but do need to accept both file paths and globs, which is actually the majority of cases, at least for me.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions