-
Notifications
You must be signed in to change notification settings - Fork 485
No longer rely on JSDoc types alone #725
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
Labels
Comments
Another JSDoc lacking: indexers. http://usejsdoc.org/tags-type.html versus There is no way to express {
size: number,
[id: number]: string
} In JSDoc - you can have a type application or a record type, but not both. |
This was referenced Apr 24, 2017
non-nullable in flow seems to be simply the variable without ? in front of it. So with flow you mark nullability: ?string |
Punting, moving conversation to dx-spec tmcw/dx-spec#2 |
mollymerp
pushed a commit
to mapbox/mapbox-gl-js
that referenced
this issue
Aug 20, 2018
Intersection types are not yet supported by documentation.js documentationjs/documentation#725 (comment) documentationjs/documentation#694
2 tasks
mollymerp
pushed a commit
to mapbox/mapbox-gl-js
that referenced
this issue
Aug 21, 2018
Intersection types are not yet supported by documentation.js documentationjs/documentation#725 (comment) documentationjs/documentation#694
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Right now documentation.js transforms Flow types to JSDoc types, so that it can run them both through format_type, which is derived from doctrine's formatter. We shouldn't do this anymore: JSDoc types can't cover everything that Flow can.
Possibly we should reverse this process and instead convert JSDoc types to Flow types. We will need to survey what the overlap and intersection of the two are in order to make an informed decision.
string|number
string|number
?string
?string
Array<string>
orstring[]
orArray.<string>
Array<string>
orstring[]
!string
type & type
[string, number]
2
The text was updated successfully, but these errors were encountered: