-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
delete stubs if the lib ends up being flow typed #4158
Comments
Good idea, but removing the stub automatically is a bit risky, let's say the user wrote some custom defs for their needs without contributing it to flow-typed. An interactive way with a prompt would be cool, obviously more work... |
We already have logic that removes stubs after a real type def is defined, but we stop if the stub has been modified. I think we could lean on the same logic there and we'll be safe |
fyi message looks like this
|
Do you want to request a feature or report a bug?
Feature
What is the current behavior?
If I install a dependency and it's not flowtyped currently we will install a stub. But if the lib becomes flow typed in the future as I'm doing right now across some libs in my team it doesn't delete the file so there needs to be manual intervention
If the current behavior is a bug, please provide the steps to reproduce.
Pretty self explanatory I hope
What is the expected behavior?
If I run
flow-typed install
and it skips because there is a typed lib, then also search if there's a stubbed module for that lib and if so delete itIf this is a feature request, what is motivation or use case for changing the behavior?
It gives a cleaner DX and encourages more flowtype users
The text was updated successfully, but these errors were encountered: