{"action":"opened","issue":{"url":"https://api.github.com/repos/nodkz/graphql-compose-mongoose/issues/11","repository_url":"https://api.github.com/repos/nodkz/graphql-compose-mongoose","labels_url":"https://api.github.com/repos/nodkz/graphql-compose-mongoose/issues/11/labels{/name}","comments_url":"https://api.github.com/repos/nodkz/graphql-compose-mongoose/issues/11/comments","events_url":"https://api.github.com/repos/nodkz/graphql-compose-mongoose/issues/11/events","html_url":"https://github.com/nodkz/graphql-compose-mongoose/issues/11","id":195949921,"number":11,"title":"How to use with graphql-compose-relay","user":{"login":"joepistritto","id":15400086,"avatar_url":"https://avatars.githubusercontent.com/u/15400086?v=3","gravatar_id":"","url":"https://api.github.com/users/joepistritto","html_url":"https://github.com/joepistritto","followers_url":"https://api.github.com/users/joepistritto/followers","following_url":"https://api.github.com/users/joepistritto/following{/other_user}","gists_url":"https://api.github.com/users/joepistritto/gists{/gist_id}","starred_url":"https://api.github.com/users/joepistritto/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joepistritto/subscriptions","organizations_url":"https://api.github.com/users/joepistritto/orgs","repos_url":"https://api.github.com/users/joepistritto/repos","events_url":"https://api.github.com/users/joepistritto/events{/privacy}","received_events_url":"https://api.github.com/users/joepistritto/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-12-16T00:09:06Z","updated_at":"2016-12-16T00:09:06Z","closed_at":null,"body":"I want to use the generated types with graphql-compose-relay but I am not sure how:\r\n\r\n```js\r\nlet UserTC = composeWithRelay(composeWithMongoose(User));\r\n\r\nUserTC.addResolver({\r\n  name: 'testResolver',\r\n  kind: 'mutation',\r\n  ...\r\n  args: {\r\n    arg1: 'String'\r\n  }\r\n});\r\n\r\nGQC.rootMutation.addFields({\r\n  'createOne': UserTC.getResolver('createOne'),\r\n  'testResolver': UserTC.getResolver('testResolver')\r\n});\r\n```\r\n\r\nIf I do the above, then `createOne` has `RelayCreateOneUserInput` type as the input argument, which I think is right for relay, but for `testResolver` it has `arg1: String` as the input argument, which I think is wrong.\r\n\r\nI tried changing where composeWithRelay is called but it's still not right:\r\n\r\n```js\r\n\r\nlet UserTC = composeWithMongoose(User);\r\n\r\nUserTC.addResolver({\r\n  name: 'testResolver',\r\n  kind: 'mutation',\r\n  ...\r\n  args: {\r\n    arg1: 'String'\r\n  }\r\n});\r\n\r\nUserTC = composeWithRelay(UserTC);\r\n\r\nGQC.rootMutation.addFields({\r\n  'createOne': UserTC.getResolver('createOne'),\r\n  'testResolver': UserTC.getResolver('testResolver')\r\n});\r\n```\r\n\r\nBut the above is still not right because now `testResolver` has `RelayTestResolverInput` type, which I think is correct but now `createOne` has `RelayCreateOneProfileInput` defined as:\r\n\r\n```\r\nrecord: CreateOneProfileInput!\r\nclientMutationId: String\r\n```\r\n\r\nSo the input argument for `createOne` got wrapped twice I think? "}}
{"actor":{"display_login":"joepistritto"}}