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

Cannot find name 'AsyncIterator' when running Angular+Apollo example #7

Open
nick-lehmann opened this issue Aug 19, 2017 · 5 comments
Assignees
Labels

Comments

@nick-lehmann
Copy link

After registering and downloading the Angular+Apollo example, the following error occurs during the build process:

ERROR in /Users/nicklehmann/Desktop/quickstart-with-apollo/node_modules/@types/graphql/subscription/subscribe.d.ts (17,4): Cannot find name 'AsyncIterator'.
ERROR in /Users/nicklehmann/Desktop/quickstart-with-apollo/node_modules/@types/graphql/subscription/subscribe.d.ts (29,4): Cannot find name 'AsyncIterable'.

npm install run just fine and did not throw any errors. A very similar issue with the same error messages was posted here. However, the proposed solution to downgrade to node 6.0 did not work.

Tested on macOS Sierra (10.12.6) with latest version you can get (installed nvm afterwards, so to figure out which exactly) and 6.0.

This workaround seems to have helped some people.

@fbcarpinato
Copy link
Contributor

I solved by adding

"esnext", es5", "es6", "dom", "es2015.core", "es2015.collection", "es2015.generator", "es2015.iterable", "es2015.promise", "es2015.proxy", "es2015.reflect", "es2015.symbol", "es2015.symbol.wellknown", "esnext.asynciterable"

To the tsconfig.json file

@marktani
Copy link
Contributor

Awesome, could you send in an PR, @fbcarpinato? 🙂

@nick-lehmann
Copy link
Author

Thanks, @fbcarpinato !!!

@daniele-zurico
Copy link

Hi guys I'm experiencing the same problem:
apollographql/graphql-subscriptions#83

@pabx06
Copy link

pabx06 commented Oct 21, 2017

changing compilerOptions.lib tsconfig.json => no changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

6 participants