You can use the Graphback CLI to generate a new GraphQL project in minutes.
Initializing with npx:
Or by installing Graphback CLI globally:
The CLI will ask you to choose from one of three templates:
apollo-fullstack-ts: Apollo GraphQL server and React client using TypeScript and PostgreSQL.
apollo-postgres-runtime-ts: Apollo GraphQL Server using Graphback runtime API and PostgreSQL database.
apollo-mongo-runtime-ts: Apollo GraphQL Server using Graphback runtime API and MongoDB database.
In a few seconds you should have an empty GraphQL application.
To change the default application configuration see Graphback Config.
See Defining your Data model for how to design your data model.
Once your data model is complete, run
graphback generatefrom your project to generate a GraphQL schema and API.
Graphback provides a number of different data sources which can be configured at application runtime. See Data Sources.
If you are using a PostgreSQL datasource you can migrate your database to match your schema. See Database Migrations for more.
Run your application!