-
Notifications
You must be signed in to change notification settings - Fork 85
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Any plan to support readdir "withFileTypes" option? #272
Comments
I had to work around this in one of my projects, and in my case it was tolerable to simply disable "modern mode" by passing Another option would be to detect if mocha is running and conditionally disable modern mode, so only your tests are affected by the performance hit, not the code your users run. Something like this would help you determine if mocha is running:
You could also try detect-mocha, but I haven't used it myself. |
Thanks for the heads up, that's what I ended up doing. Native support would be awesome though. |
I'm not sure to understand the workaround... Then how do you pass |
It's indeed only a workaround for usage with If your code (or one of your dependencies) make use of the new Node 10.10+ |
@tschaub, maybe it's time to release a new version? |
fast-glob uses this option since v3 in its "modern mode" to make fewer calls to file system.
Using it in combination with mock-fs leads to the following error:
The text was updated successfully, but these errors were encountered: