-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ability to whitelist/blacklist modules that should (not) be decached #47
Comments
@Risker good suggestion. |
@nelsonic |
right, that's what I was trying to understand ... if one of the dependencies is requiring and thus "decaching" I don't quite see the use case for the "blacklist" though ... surely if a module is not listed in the whitelist it would always be decached, isn't that the desired behaviour? 💭 We could implement the whitelist functionality quite easily but we need to have a very clear acceptance criteria so that we can write the tests. 📝 |
Yeah. I initally thought about the blacklist as the opposite of whitelist - so that all modules that do not match the regex patterns get uncached. So that:
I really don't need both, only one of them. I'm trying to apply this to a lerna monorepo which means that many modules depend on other modules that are in my direct control, but exist (symlinked) in the node_modules directory. So, with:
For me, the AC would be: |
This is somewhat related to #29 but a more specific feature request so filing it separately.
I'm running into some issues with
decache
uncaching instances ofreact
andreact-dom
, so I'm getting errors like:I'm really guessing here, but it seems that deleting and re-requiring
react
causes some identity change for the library and... just ruins everything :)This is most probably a very specific issue related to my dev environment, but I can pretty safely say that I do not need to uncache these modules (nor some other third party dependencies) since I'm not actively working on them.
Proposed syntax:
The text was updated successfully, but these errors were encountered: