React Query Codegen from OpenAPI

This page summarizes the projects mentioned and recommended in the original post on dev.to

Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • rapini

    :leafy_green: OpenAPI to React Query (or SWR) & Axios

  • Once you generate the custom npm package using rapini, you can start to import all the react query hooks, types, requests and query keys from the package. Let's say you generated your package with output name of my-package, like this: rapini -p path/to/openapi.yaml --output-dir /my-package then you can start importing like this:

  • react-query

    Discontinued 🤖 Powerful asynchronous state management, server-state utilities and data fetching for TS/JS, React, Solid, Svelte and Vue. [Moved to: https://github.com/TanStack/query]

  • Rapini is a new tool that can generate custom React Query hooks using OpenAPI (Swagger) files.

  • 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.

    SurveyJS logo
  • axios

    Promise based HTTP client for the browser and node.js

  • The Command Line Interface (CLI) tool will take a path to an Open API file and generate a package that includes react hooks, typescript types and axios http requests - and this package is conveniently bundled in a way that it can be published to NPM or any other package registry of your choosing.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts