All Projects → praveenweb → swr-graphql

praveenweb / swr-graphql

Licence: other
A sample Next.js app using Zeit's SWR React Hooks to make GraphQL Queries/Mutations/Subscriptions

Programming Languages

javascript
184084 projects - #8 most used programming language
CSS
56736 projects

Projects that are alternatives of or similar to swr-graphql

Swr
React Hooks for data fetching
Stars: ✭ 20,348 (+17291.45%)
Mutual labels:  zeit, swr
perseus
An Apollo GraphQL Server & React Client in a Yarn Workspace deployed with Zeit 2.0
Stars: ✭ 35 (-70.09%)
Mutual labels:  zeit
graphql-codegen-plugin-typescript-swr
A GraphQL code generator plug-in that automatically generates utility functions for SWR.
Stars: ✭ 88 (-24.79%)
Mutual labels:  swr
webfunc
Universal Serverless Web Framework. Write Express apps ready to be deployed to Zeit-Now, Google Cloud Functions (incl. functions reacting to Pub/Sub topics or Storage changes), and AWS Lambdas.
Stars: ✭ 71 (-39.32%)
Mutual labels:  zeit
now-swift-example
Example for use Kitura framework and swift lang with https://zeit.co/now.
Stars: ✭ 18 (-84.62%)
Mutual labels:  zeit
micro-unfurl
Small microservice that unfurls a URL and returns the OpenGraph meta data
Stars: ✭ 28 (-76.07%)
Mutual labels:  zeit
xkcd-api
💪 CORS enabled version of the XKCD API
Stars: ✭ 37 (-68.38%)
Mutual labels:  zeit
now dashboard
▲ZEIT dashboard written in elm
Stars: ✭ 52 (-55.56%)
Mutual labels:  zeit
mailto
💌 ⚡️ The mailto encoder
Stars: ✭ 157 (+34.19%)
Mutual labels:  zeit
unity-now
▲ Vercel Now plugin for Unity. Deploy WebGL builds with ease
Stars: ✭ 21 (-82.05%)
Mutual labels:  zeit
Temps
λ A selfhostable serverless function runtime. Inspired by zeit now.
Stars: ✭ 15 (-87.18%)
Mutual labels:  zeit
swr-mutate-many
Little function to call mutate against multiple cached keys of SWR
Stars: ✭ 26 (-77.78%)
Mutual labels:  swr
micro-visualize
Visualizes requests and responses for services written with micro
Stars: ✭ 55 (-52.99%)
Mutual labels:  zeit
netlify-cms-oauth-provider-node
A stateless external OAuth provider for netlify-cms with built-in support for Vercel serverless functions
Stars: ✭ 30 (-74.36%)
Mutual labels:  zeit
now-compose
Docker compose for zeit now. [deprecated]
Stars: ✭ 80 (-31.62%)
Mutual labels:  zeit
next-go
Production ready blog + boilerplate for Next.js 3.X
Stars: ✭ 255 (+117.95%)
Mutual labels:  zeit
booktez-client
📚진짜 독서가들의 독서법 - 북스테어즈 (React)
Stars: ✭ 53 (-54.7%)
Mutual labels:  swr
example-next-isr-with-swr
Lightning fast static pages with ISR, instantly updated with SWR ⚡️
Stars: ✭ 48 (-58.97%)
Mutual labels:  swr
swr-devtools
A DevTool for SWR
Stars: ✭ 45 (-61.54%)
Mutual labels:  swr
docker-craft-nginx
🐳 A minimal Docker container for Craft CMS, intended for use with zeit-now.
Stars: ✭ 26 (-77.78%)
Mutual labels:  zeit

swr-graphql

The Idea behind the Example

This is a sample app demonstrating usage of useSWR, mutate and trigger of SWR library with a Hasura GraphQL API. The app uses native websockets for implementing GraphQL subscriptions on the client.

  • Hasura GraphQL APIs for instant GraphQL backend.
  • Integrate simple GraphQL queries.
  • Optimistic UI with GraphQL mutations.
  • GraphQL Subscriptions using native websockets.

Deploy Hasura to get a GraphQL API

  1. Click on the following button to deploy GraphQL engine on Hasura Cloud including Postgres add-on or using an existing Postgres database:

    Deploy to Hasura Cloud

  2. Open the Hasura console

    Click on the button "Launch console" to open the Hasura console.

  3. Create table users

    Head to the Data tab and create a new table called users with columns: id (text), name (text), created_at (timestamp now()).

  4. Try out a GraphQL Query

    query {
        users {
            id
            name
            created_at
        }
    }

One-Click Deploy

Deploy your own SWR project with ZEIT Now.

Deploy with ZEIT Now

How to Use

Install it and run:

yarn
yarn dev
# or
npm install
npm run dev

Deploy it to the cloud with now (download)

now
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].