-
Notifications
You must be signed in to change notification settings - Fork 12
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
Inference based on conventions #163
Comments
Please explain more what you are trying to achieve. But basically, if I've correctly understood your question, when you add to graphql router Also, a great code example about routes and resources actions handling is here. |
I think what confuses me is your first example UsersController does not
define index,show,create,update,delete actions
That led me to think those actions would automatically exist
On October 17, 2020, GitHub ***@***.***> wrote:
Please explain more what you are trying to achieve.
But basically, if I've correctly understood your question, when you
add to graphql router resources :users graphql_rails expects that you
have these actions (and methods which correspond to these actions)
defined in your graphql rails controller (like in this example
<https://github.com/samesystem/graphql_rails#define-controller>.
Also, a great code example about routes and resources actions handling
is here <https://github.com/samesystem/graphql_rails#routes>.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#163 (comment)-
711083473>, or unsubscribe
<https://github.com/notifications/unsubscribe-
auth/AAAAXCVPL35VE6WZIEOE4BLSLIE7TANCNFSM4SUSVXEA>.
|
Hey, @chrisortman. Sorry for the delayed response, but just to be short - defining a resource currently does not define actions in the controller itself, meaning you have to add them manually. However, you're correct on it sort of misleading you in the documentation/examples, and we'll update that soon. Leaving the issue as open before we do that. |
Hello. I can't quite tell if this library will infer any controller actions and model based on conventions or if I am supposed to always specify it.
We could infer:
I don't see these lines in the example, but they appear to be required?
The text was updated successfully, but these errors were encountered: