diff options
Diffstat (limited to 'src/Language/GraphQL.hs')
| -rw-r--r-- | src/Language/GraphQL.hs | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/Language/GraphQL.hs b/src/Language/GraphQL.hs index b64cf42..4f3e8d9 100644 --- a/src/Language/GraphQL.hs +++ b/src/Language/GraphQL.hs @@ -4,6 +4,28 @@ #ifdef WITH_JSON -- | This module provides the functions to parse and execute @GraphQL@ queries. +-- +-- The content of this module depends on the value of the __json__ flag, which +-- is currently on by default. This behavior will change in the future, the flag +-- will be switched off by default and then removed. +-- +-- This documentation is generated with the enabled __json__ flag and functions +-- described here support JSON and are deprecated. JSON instances are provided +-- now by an additional package, __graphql-spice__. To start using the new +-- package create __cabal.project__ in the root directory of your project with +-- the following contents: +-- +-- @ +-- packages: . +-- constraints: graphql -json +-- @ +-- +-- Then add __graphql-spice__ as dependency. +-- +-- The new version of this module defines only one function, @graphql@, which +-- works with the internal GraphQL value representation used by this lbirary. +-- Refer to @Language.GraphQL.JSON.graphql@ in __graphql-spice__ for the +-- function that accepts and returns JSON. module Language.GraphQL ( graphql , graphqlSubs @@ -23,6 +45,7 @@ import qualified Language.GraphQL.Validate as Validate import Language.GraphQL.Type.Schema (Schema) import Text.Megaparsec (parse) +{-# DEPRECATED graphql "Use graphql-spice package instead" #-} -- | If the text parses correctly as a @GraphQL@ query the query is -- executed using the given 'Schema'. graphql :: MonadCatch m @@ -31,6 +54,7 @@ graphql :: MonadCatch m -> m (Either (ResponseEventStream m Aeson.Value) Aeson.Object) -- ^ Response. graphql schema = graphqlSubs schema mempty mempty +{-# DEPRECATED graphqlSubs "Use graphql-spice package instead" #-} -- | If the text parses correctly as a @GraphQL@ query the substitution is -- applied to the query and the query is then executed using to the given -- 'Schema'. |
