2 ms·
Funny you should mention access control. One of the stumbling blocks for me when I did a bit of GraphQL work was adhering to the best practices listed here: htt
by criddell 5y ago
Funny you should mention access control. One of the stumbling blocks for me when I did a bit of GraphQL work was adhering to the best practices listed here: https://graphql.org/learn/authorization/ https://graphql.org/learn/authorization/
That says authorization should not be in the resolver but putting it elsewhere often resulted in much more complicated code. It makes sense if GraphQL is coexisting with REST or other end points because they could all share the same authentication code, but for pure GraphQL projects it seems arbitrary.
- dmitryminkovsky 5y agoYes those docs bewildered me a bit as well. I never got too far with all of that or building a GraphQL server in JS for that matter. The authorization/access control in Hasura is game changing.