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

@Arg not recognized in resolver #530

Closed
MikyStar opened this issue Feb 1, 2020 · 1 comment
Closed

@Arg not recognized in resolver #530

MikyStar opened this issue Feb 1, 2020 · 1 comment
Labels
Duplicate 🔑 This issue or pull request already exists

Comments

@MikyStar
Copy link

MikyStar commented Feb 1, 2020

Describe the bug

It seems like the @arg annotation doesn't work in my resolver => https://github.com/MikyStar/IDLE/blob/typegraphql/server/src/graphql/User.ts line 56

To Reproduce

Just clone my repository https://github.com/MikyStar/IDLE, cd server && npm i && npm start

Expected behavior

Being able to use arguments in my mutations and querries

Logs

[...]/IDLE/server/lib/graphql/User.js:135
async login(@(0, _typeGraphql.Arg)("token")
^

SyntaxError: Invalid or unexpected token
at Module._compile (internal/modules/cjs/loader.js:892:18)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:973:10)
at Module.load (internal/modules/cjs/loader.js:812:32)
at Function.Module._load (internal/modules/cjs/loader.js:724:14)
at Module.require (internal/modules/cjs/loader.js:849:19)
at require (internal/modules/cjs/helpers.js:74:18)
at Object. (/Users/mike/Documents/depots/IDLE/server/lib/index.js:23:13)
at Module._compile (internal/modules/cjs/loader.js:956:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:973:10)
at Module.load (internal/modules/cjs/loader.js:812:32)

Enviorment (please complete the following information):

  • OS: macOS
  • Node : v12.12.0
  • Package version : npm v6.12.0
  • TypeScript version : ^3.7.3
@MichalLytek
Copy link
Owner

#55 (comment)

Closing as duplicate 🔒

@MichalLytek MichalLytek added the Duplicate 🔑 This issue or pull request already exists label Feb 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Duplicate 🔑 This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants