es-tooling / module-replacements

A manifest of JS modules and their more modern/active replacements
MIT License
496 stars 25 forks source link

`glob` #50

Open benmccann opened 3 months ago

benmccann commented 3 months ago

here's an example: https://github.com/rollup/plugins/pull/1741

43081j commented 3 months ago

im unsure of this one for now

glob is still a fairly useful package, though it could be good to list the alternatives somewhere still

i wonder if for glob, we add the docs for alternatives but we don't yet add it to the preferred manifest. maybe it belongs in some other manifest in future for "lighter dependencies" or something (as the packages being replaced are not necessarily "bad", we just want to make alternatives known)

benmccann commented 3 months ago

Different glob libraries do have slightly different functionality. new fdir().glob() which I linked in the example does do globbing. Any differences I'm aware of are pretty minimal, but it would be nice to highlight if there are major differences

valadaptive commented 3 months ago

I think fdir's behavior around directories is different enough to highlight. new fdir().glob() isn't equivalent to glob because it doesn't include directories by default, and doesn't match directory paths unless they end in a trailing slash.