fringe-workers
A experimental project to execute GraphQL queries/mutations on Cloudflare Edge.
This template is meant to be used with Wrangler. If you are not already familiar with the tool, we recommend that you install the tool and configure it to work with your Cloudflare account. Documentation can be found here.
To generate using Wrangler, run this command:
wrangler generate my-ts-project https://github.com/bishwenduk029/fringe-workers
The purpose of project is to execute any kind of DB/GraphQL queries/mutations on Cloudflare's amazing and secure EDGE network.
File system based routing - Any .graphql file inside graphql folder, becomes accessible at REST endpoint /graphql/*
For example query residing at /graphql/space/index.graphql
is mapped to /graphql/space
(Method = POST)
1.) Inside graphql folder add your queries/mutations in plain .graphql
2.) Provide the URL for your GraphQL API in wrangler.toml
3.) Now open any REST client of your choice (say POSTMAN)
4.) Start accessing your REST endpoints via POST method.
For information on how to preview and publish your worker, please see the Wrangler docs.
1.) Add support for normalized caching for GraphQL on Cloudflare KV ( in-progress )
2.) Add similar support for .sql files
If you have any feedback or enhancement ideas please feel free to share them here.