NavidK0 / SimpleGraphQL-For-Unity

A simple graphQL client that allows one to use .graphql files (or code) for queries, mutations, and subscriptions with Unity.
MIT License
34 stars 18 forks source link

Make use of variables more ergonomic #14

Closed johanhelsing closed 3 years ago

johanhelsing commented 3 years ago

Using object instead of a Dictionary

Similarly to how it's done in graphql-dotnet and the other unity project.

I think this will break binary compatibility, but sending requests should be source compatible (see tests).

NavidK0 commented 3 years ago

Have you looked into this more? Now that we have the linker stuff working, this is probably worth revisiting.

johanhelsing commented 3 years ago

Have you looked into this more? Now that we have the linker stuff working, this is probably worth revisiting.

It's actually part of the other pr that just got merged :)

The tests use it, but I haven't actually tested using anonymous objects in il2cpp builds. It may be that the members of the anonymous types are stripped an that it requries yet another link.xml entry for AssemblyCSharp's anonymous types.

NavidK0 commented 3 years ago

Understood, thanks a lot for the update! 😄