Leonardo Losoviz
Jan 12, 2022 ⋅ 7 min read

Fetching dynamically structured data in a CMS with GraphQL

Leonardo Losoviz Freelance developer and writer, with an ongoing quest to integrate innovative paradigms into existing PHP frameworks, and unify all of them into a single mental model.

Recent posts:

Vite Adoption Guide Overview Examples And Alternatives

Vite adoption guide: Overview, examples, and alternatives

Vite is a versatile, fast, lightweight build tool with an exceptional DX. Let’s explore when and why you should adopt Vite in your projects.

David Omotayo
Nov 29, 2023 ⋅ 16 min read
Implementing Advanced Features With The Navigator.Share API

Implementing advanced features with the navigator.share API

Explore advanced capabilities for content sharing with the navigator.share API, including dynamic content sharing, custom share targets, and batch sharing.

David Omotayo
Nov 29, 2023 ⋅ 10 min read
Chas Peacock Leader Spotlight

Leader Spotlight: Scaling for the next phase of growth with Chas Peacock

We spoke with Chas to get his insights on building technology and internal processes for companies that are scaling quickly.

Jessica Srinivas
Nov 29, 2023 ⋅ 7 min read
Cypress Adoption Guide: Overview, Examples, Alternatives

Cypress adoption guide: Overview, examples, and alternatives

Cypress is one of today’s foremost tools for testing web applications. Let’s explore when and why you should adopt Cypress in your projects.

Paul Akinyemi
Nov 28, 2023 ⋅ 10 min read
View all posts

4 Replies to "Fetching dynamically structured data in a CMS with GraphQL"

  1. Been playing around with WPEngine’s FaustJS. It uses gqty to dynamically build GraphQL queries, which means you can just loop through the indeterminate number of children without worrying about how many levels you need to nest your queries.

    1. Sounds interesting, I’d like to learn more, if you don’t mind. How do you like using gqty versus composing the queries manually? Do you like the experience, or is it too hand-off? Benefits/disadvantages you’ve encountered so far?

      1. From my experience, there’s 2 types of devs in the WP Headless space: frontend devs looking to use WP as a cms, and WP devs looking to break free of the native php frontend shackles while still benefiting from the ecosystem.

        I’m in the latter camp, and gqty definitely helps me and my WP_Query() trained brain, where I can focus on what to do with the data instead of wasting time writing hundreds of lines of gql in order to retrieve it.

        Only downside _for me_ is that the docs are pretty sparse, though the folks at gqty and WPEngine’s discords are very helpful. There are some advanced graphql cases that gqty doesn’t handle… Or so I’m told, haven’t run into any issues yet, but that’s prob because I anyway don’t know how to do those things in graphql. That said, there’s nothing stopping you from using regular graphql for a specific query (like how Gatsby users handle mutations).

Leave a Reply