Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display GraphQL query as plain string #28

Open
phjardas opened this issue Jun 27, 2018 · 4 comments
Open

Display GraphQL query as plain string #28

phjardas opened this issue Jun 27, 2018 · 4 comments

Comments

@phjardas
Copy link

  • apollo-link-logger version: 1.2.0

Hi folks, first of all, thanks for this cool tool!

I was wondering, would it be possible to render the AST query back to a simple string? It's really cumbersome to navigate through the tree nodes of the compiled query.

I'd be happy to work on a fix and submit a PR if this feature would be welcome.

@blackxored
Copy link
Owner

blackxored commented Jun 27, 2018 via email

@div-dog
Copy link

div-dog commented Dec 19, 2019

@phjardas have you done any work on this? I would be interested in something similar and could be willing to contribute to the PR.

@phjardas
Copy link
Author

@div-dog I haven't done anything in this regard because I'm not using this library anymore but the DevTools instead. Feel free to contribute!

@div-dog
Copy link

div-dog commented Dec 20, 2019

Looks like the plain query string can be found in the INIT operation object in the logs with a bit of digging. It's in query.loc.source.body.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants