Hi dgraph hivemind,
DQL cannot be used with Apollo Client, is that right?
My readings suggest that it wouldn’t work.
The references/examples within dgraph community are usually mentioning Apollo Client in combination with GraphQL. I can’t imagine how Apollo Cache would work with DQL given that it seems to parse the request to map them to cached results.
On the other hand, I just came across this
@custom that shook me… altho as I was reading more about it… and realized that maybe it has completely another purpose, and it wouldn’t be something that I can just put together on a client to fake a GraphQL request which in fact is wrapping a DQL one… seems like it would need to be declared on the schema definition on a server-side. Even if would be a wrapping I could do on the client, it doesn’t seem to make sense that Apollo would be able to understand/parse this query anyhow.
Before the answers go too far from the question, I’d share some extra context.
I already have a client that sends DQL to a backend. I’m just looking to replace what exists with another piece of software that handles more FE features such as, for example, optimistic responses. In reality, what I’d like to replace for simply doesn’t exist yet… I need a reactive state manager that syncs with the Dgraph cluster. I saw a discussion about GraphQLite which goes towards what I’m looking for, but it looks multiple years away.
Therefore, I’m looking at Apollo as a first step and also as a learning/stepping stone for building something else.