Skip to content
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

Support flow type without configuration #1819

Closed
michalkvasnicak opened this issue Jun 23, 2017 · 2 comments
Closed

Support flow type without configuration #1819

michalkvasnicak opened this issue Jun 23, 2017 · 2 comments

Comments

@michalkvasnicak
Copy link
Contributor

I want to typecheck using flow in my project but it isn't working without configuration because there is no apollo.umd.js.flow file.

As in apollographql/graphql-tag#98, copying index.js.flow to apollo.umd.js.flow should do the job just fine.

@michalkvasnicak
Copy link
Contributor Author

Actually I tried copy the file and it does not work just as is.

@michalkvasnicak
Copy link
Contributor Author

michalkvasnicak commented Jun 23, 2017

Ok so after investigation. index.flow.js shouldn't be in lib-def format because then you have to install it using flow-typed or point to it in .flowconfig. Also importing types from other lib-defs does not work now in flow.

Next thing is to use RequestOptions type from flow definitions instead of RequestInit from fetch lib.

And last thing is install lib defs using flow-typed and import Middleware from redux.

@michalkvasnicak michalkvasnicak changed the title Copy index.js.flow as apollo.umd.js.flow too Support flow type without configuration Jun 23, 2017
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 17, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant