Vincit/venia

Too many vectors in syntax

Opened this issue · 0 comments

In order to generate this GraphQL query:

employees(first: 5, after: $cursor) {
    edges {
      node {
        dbId
        description
      }
    }
  }

Venia requires this syntax:

[
 [:employees {:first 5 :after :$cursor}
  [
   [:edges
    [
     [:node
      [:dbId :description]]]]]]]

Is there a good reason to require the extra vector before and after the [:edges line? Why not just treat all elements after the field name as a nested selection?

For example, in hiccup, syntax like this is supported: [:div {} [:p "test"]]. You don't need to wrap [:p "test"] in yet another vector.