Fork me on GitHub
#graphql
<
2019-04-10
>
donaldball18:04:44

I have definitely gone down the higher-level abstraction route and am moderately pleased with the results thus far.

donaldball18:04:11

My question of the day today is: has anyone used a pattern they liked for providing an answer to the question: could this user perform this mutation? E.g. for driving the decision in a UI to even render the form or widget to take an action?

orestis18:04:32

Oh I like the question. You could certainly expose a meta query for this!

donaldball18:04:23

That’s kind of where I think I’m going; a :could query that takes as arguments the name of and the input to a mutation

timgilbert18:04:36

Say, I'm trying to rapidly mock up some data in lacinia for a deeply-nested structure. Is there a way to get it to ignore my previously-declared resolvers for a certain subset or the tree? Like I just want to return a literal map {:foo {:bar "baz"}} but have lacinia ignore my previously-declared resolver for the :bar field

donaldball00:04:44

If it were me, I reckon I’d just attach new resolvers, recompile, and query the new database.