A JavaScript template literal tag that parses GraphQL query strings into GraphQL documents that can be used to do NerdGraph queries.
Usage
import { ngql } from 'nr1'
Examples
Example 1
import { ngql } from 'nr1';
const query = ngql` { actor { user { id email name } } }`;
function render() { return ( <NerdGraphQuery query={query}> {({ data }) => JSON.stringify(data, null, 2)} </NerdGraphQuery> );}