Skip to content

this repository will contain flutter applications using various libraries designed to work with GraphQL

Notifications You must be signed in to change notification settings

YuryMorozov2001/graphql-and-flutter

Repository files navigation

Flutter + GraphQL

preview

Hi! This repository will contain flutter applications using various libraries designed to work with GraphQL.

todo:

  • graphql_flutter
  • graphql_flutter with hooks
  • graphql_flutter with code gen
  • just graphql

Getting started

Hasura

Get the docker-compose file

Get the docker-compose.yaml file from this repository or clone via terminal:

# in a new directory run
wget https://raw.githubusercontent.com/hasura/graphql-engine/stable/install-manifests/docker-compose/docker-compose.yaml
# or run
curl https://raw.githubusercontent.com/hasura/graphql-engine/stable/install-manifests/docker-compose/docker-compose.yaml -o docker-compose.yml

Run Hasura GraphQL engine

Run the command to start the hasura:

$ docker compose up -d

After docker starts the graphql container, go to the url localhost:8080/

Create tables

You can read about how to create a database and a schema here:

https://hasura.io/docs/latest/getting-started/docker-simple/

Create simple tables following this diagram:

diogram

Congrats! Now you can make a request to a GraphQL API!

Flutter client

Clone project following this command:

$ git clone https://github.com/YuryMorozov2001/graphql-and-flutter.git

And run this command in the flutter client path

$ flutter pub get
$ flutter run

About

this repository will contain flutter applications using various libraries designed to work with GraphQL

Topics

Resources

Stars

Watchers

Forks

Languages