Closed pkuczynski closed 5 years ago
Do you want me to add some tests before you merge it in?
@pkuczynski One simple test would be great :)
Sure! The only reason why I haven’t done this so far was that I wasn’t really sure if you would accept this contribution and like the idea.
I will add a test tomorrow, when I get back to my laptop.
Any chance this would be merged and released anytime soon?
Yes, we can release quickly after.
Tests added. I change path-exists
to globby
, as it makes it a bit easier to require files by the pattern. I hope you don't mind?
Looking forward to hearing some feedback for you and get this released...
@pkuczynski Thank you
Thanks! :)
This PR brings new feature (from README.md)
Regular expressions
If you are using Babel 7 or newer and your config is stored in
babel.config.js
, you can also use a regular expression to describe modules, which should be removed.This would be particularly useful when using custom prop types validators, implemented as part of your own source code. For example
would be removed with the following setting
If you use an index file
you could set it up as