-
-
Notifications
You must be signed in to change notification settings - Fork 399
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
Move flow types to .flow typedef files #1509
Conversation
} | ||
|
||
declare export default class PluginsRegistry { | ||
plugins: {| |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would we even need to declare this as I wouldn't consider this to be a "public" API and shouldn't really be accessed from the outside?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, was my question as well, since typings are only used from outside, I am not sure internally used types provide any additional type safety, unless used from outside, but thats not going to happen
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it should be removed as long as we only want to use these types for the outside and not for internal type checking
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just tried, can't remove completely all private fields from .flow, it's still gonna be a mixture of public apis and internal once, otherwise it won't compile
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because some fields are accessed by jss core itself, from other modules, for actual public api we would need to differentiate that and the access from public apis
Data could contain theme but it doesn't have to
e7efd5c
to
117dcb8
Compare
I finally finished moving all flow types in all packages, once this is merged, nothing stops us from using ts |
merged now we can add ts types |
#1035