Our great sponsors
-
graphql-code-generator
A tool for generating code based on a GraphQL schema and GraphQL operations (query/mutation/subscription), with flexible support for custom plugins.
-
SurveyJS
Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.
So I tried combining graphql-request with SWR (React Hooks library for data fetching), and the bundle size was about 1/3 of the Apollo-Client combined with these two libraries, and I had the best experience of using the advanced features of SWR!
Based on the above experience, I have created a GraphQL Code Generator plugin called graphql-codegen-plugin-typescript-swr that facilitates the combination of graphql-request and SWR, and published it to NPM!
Related posts
- Build Smarter, Not Harder: Simplifying Backend Workflows with Build-time GraphQL
- Typed GraphQL with react-query & graphql-request
- Consumindo uma API GraphQL com SWR
- Type-Safe Fetch with Next.js, Strapi, and OpenAPI
- A day in the life of a developer - Building a dashboard app with SQL, Node.js, Django and Next.js