µGQL
Leveraging GraphQL-js with µWebSockets.js
Installation
npm i ugql
or yarn add ugql
Usage
Create an app.mjs
file with the following content:
;;; const buildSchema = gql;const app = uWS;const ugraphql = ; const schema = ; const root = 'Hello world'; ; app;
Then run
node --experimental-modules app.mjs
Quick test, in a developer console
;
You should see
Object hello: "Hello world!"
Supported request's types
- GET with query parameter
- POST with content-type
- application/json
- application/x-www-form-urlencoded
- application/graphql