npm install -g prisma
# OR
yarn global add prisma
prisma init your-project-name
Note: Select Demo server and register with Prisma Cloud (e.g. using your GitHub account)
cd your-project-name
prisma deploy
Note: Do it each time you update the schema for now (we will add a post-deploy hook later )
prisma playground
-
Prisma initiated with default data model
git checkout v0
-
Data model updated with
Post
typegit checkout v1
For fetch
example:
yarn init -y
yarn add node-fetch
Install Prisma bindings
yarn add prisma-binding graphql
Install graphq-cli to download Prisma's auto-generated GraphQL schema
yarn global add graphql-cli
Get remote schema (after adding .graphqlconfig.yml)
graphql get-schema
-
Example of calling prisma gql queries with
fetch
git checkout v1.1
-
Clean up before adding Prisma bindings
git checkout v2
-
git checkout v2.1
-
git checkout v2.2