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

Error when using async/await #439

Closed
ilearnio opened this issue Feb 24, 2016 · 2 comments

Comments

@ilearnio
Copy link

commented Feb 24, 2016

I have such code

const api_wrapper = {
  async query () { // <- Error here
    return api.query(...arguments)
  }
}

which gives me "Parsing error: Unexpected token query (null)".

Currently, I'm using the default parser. I thought it was the reason for this error, so I set "parser" to "babel-eslint". But it does not help. It seems that it's not even reacting when I change the "parser" option in my package.json. I even tried to set any random value to it but the linter is working like nothing happened.

How do I set the babel-eslint parser properly? Or maybe the problem is in something else?

Thanks

@ilearnio

This comment has been minimized.

Copy link
Author

commented Feb 24, 2016

I was wrong, it is reacting when I change the parser. I have it now set to babel-eslint but the error is still there. How can I fix it?

@ilearnio

This comment has been minimized.

Copy link
Author

commented Feb 24, 2016

I finally figured why it was happening. It appered that I had another package.json in one of my subdirectories which had no "standard" configuration. Sorry, my bad. Closing...

@ilearnio ilearnio closed this Feb 24, 2016

@lock lock bot locked as resolved and limited conversation to collaborators May 10, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
1 participant
You can’t perform that action at this time.