npm fast-glob 3.0.0

latest releases: 3.3.2, 3.3.1, 3.3.0...
4 years ago

🌮 Thanks

📑 Summary

This release aims to fix architectural issues, increase performance and reduce size of package.

💣 Breaking changes

Since this is a major release, we are introducing a few breaking changes:

  • Support for the fast-glob@2 is ending.
  • Require Node.js 8+. But we recommend using 10.10+ for performance issues.
  • Only forward-slashes in glob expression. Previously, we convert all slashes to the forward-slashes, which did not allow the use of escaping. See pattern syntax section in the README.md file.
  • Removed options: nobrace, noglobstar, noext, nocase, transform.
  • Renamed options:
  • The deep option now accepts only number type and default value now is Infinity instead of true.
  • The async method was removed. Use fg(/* … */) instead.
  • The type of returned object when the stats option is enabled is completely changed.

🐛 Bug fixes

  • After update from micromatch@3 to micromatch@4:
    • Incorrect matching with curly braces and globstar (#159).
    • Inaccurate comparison within a regular expression (#123, #138).
    • A very long initialization time of filters (#92).
  • Now we do not convert slashes in patterns (#173).
  • Previously, the baseNameMatch option never worked (#199).

🚀 Improvements

💬 Common

  • Package size after installation is decreased: 2.47MB0.42MB.
  • Package require time decreased: 534ms78ms.

🌪️ Speed

Wow! The new version is very fast. At least twice as fast as the previous version. Probably this is the fastest solution in the Node.js world. And that's not all! We will work on performance issues in the future 🐢.

  • Speed up between versions for directory with 265k entries: 5x (19s → 4s).
  • Speed up between versions for directory with 4kk entries: 4x (4m → 1m).

Look at the benchmarks section in the README.md file.

⚙️ Flexibility

Also in this release we have worked on simplifying some scenarios.

Now, thanks to the new mechanism, you can get the type of entry without additional costs! Works only on Node.js 10.10+. Look at the objectMode option.

🤕 Known issues in this update

Don't miss a new fast-glob release

NewReleases is sending notifications on new releases.