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

Fix issues preventing the queries tab from working #149

Merged
merged 2 commits into from
Oct 31, 2018

Commits on Oct 30, 2018

  1. Fix issues preventing the queries tab from working

    Currently, the code to extract a query name to show in the
    queries panel, expects the incoming query to always have
    the `document.loc.source` attribute available. If this
    attribute isn't available, an exception is thrown, and the
    queries panel is displayed as a blank page. These changes
    adjust the logic used to extract a query label to be more
    flexible. The query name is now derivd by attempting
    the following (in order):
    
    1. Attempt to parse and extract a query name from
    an incoming query string.
    2. Check to see if the incoming query has already
    been parsed; if so extract the query name from the
    parsed document (e.g. happens when using `graphql-tag`).
    3. If the incoming query has already been parsed, but
    the query name can't be extracted from the result, see
    if the document includes the original query source. If
    so, try re-parsing it, and re-extracting the query name.
    4. If all else fails, fallback on using the query
    ID as the query name.
    
    Fixes #137.
    hwillson committed Oct 30, 2018
    Configuration menu
    Copy the full SHA
    95345e8 View commit details
    Browse the repository at this point in the history

Commits on Oct 31, 2018

  1. Changelog update

    hwillson committed Oct 31, 2018
    Configuration menu
    Copy the full SHA
    431ce5f View commit details
    Browse the repository at this point in the history