Skip to main content
Module

x/dgql/deps.ts>gql

0 config deno full featured graphql side car. Generate gql from any datasource.
Latest
function gql
import { gql } from "https://deno.land/x/dgql@v0.0.2/deps.ts";

Create a GraphQL AST from template literal

Examples

Example 1

import { buildASTSchema, graphql } from 'https://deno.land/x/graphql_deno@v15.0.0/mod.ts'
import { gql } from 'https://deno.land/x/graphql_tag/mod.ts'

const typeDefs = gql`
 type Query {
   hello: String
 }
`

const query = `{ hello }`

const resolvers = { hello: () => 'world' }

console.log(await graphql(buildASTSchema(typeDefs), query, resolvers))

Parameters

literals: string | readonly string[]
...args: any[]