GraphQL v0.3.2 Mix.Tasks.Compile.Graphql
Compiles .graphql
files which have changed since the last generation.
Currently only handles schema files, but will support queries in future.
To use this you need to add the :graphql
compiler to the front ofyour compiler chain.
This just needs to be anywhere before the Elixir compiler because we are
generating Elixir code.
In your mix.exs
project in a Phoenix project for example:
compilers: [:phoenix, :graphql] ++ Mix.compilers
You also need to tell the GraphQL compiler which files to pick up.
In config/config.exs
config :graphql, source_path: "web/graphql/**/*_schema.graphql"
Command line options
--force
- forces compilation regardless of modification times