@formity/react

中文文档
3.0.0发布于 2026/06/10MITTypeScriptESM + CJS近 30 天下载 1.2万

React multi-step forms where logic has no limits - for any use case

原始使用文档
文档目录6 节
  1. Featured by
  2. Key features of formity
  3. Advanced logic
  4. Integration with any form library
  5. Advanced type inference
  6. License

Formity

Multi-Step Forms Where Logic Has No Limits

Formity is a React library for building advanced multi-step forms where you have full control over the flow — use variables, conditions, loops, and any logic you need to make your forms as dynamic as you want.

Website · Formity UI · Discord


animation

"I highly recommend Formity for creating multi-step forms. It saves you from building it yourself, which is an enormous pain. After building these a million times myself, it's awesome to finally see one that handles everything so well."

— midudev (500k+ subscribers) | Watch video

"With Formity's pattern for steps, logic, and animations, you can give your coding agent a skill for building multi-step forms - so any time you need one, your forms are way more consistent and follow the same structure."

— Hamed Bahram (200k+ subscribers) | Watch video

Key features of formity

Advanced logic

You can add sophisticated logic to your multi-step forms using conditions, loops, and variables — creating truly dynamic forms where the flow adapts to every user.

Integration with any form library

Formity integrates seamlessly with your favorite form library — React Hook Form, Formik, TanStack Form or any other form-handling tool.

Advanced type inference

For TypeScript users, Formity offers advanced type inference for a smooth and error-free developer experience — with better autocomplete and improved type safety.

advanced type inference

License

This package is licensed under the MIT license.

版本与发布记录

@formity/react 共发布 17 个版本,首次发布于 2024/12/31;过去 12 个月发布了 8 个版本。

版本发布日期距今
3.0.0latest2026/06/105 个月前
2.0.02026/05/076 个月前
1.0.62026/03/227 个月前
1.0.52026/03/148 个月前
1.0.42026/03/028 个月前
1.0.32026/02/278 个月前

关于 @formity/react 的常见问题

@formity/react 是什么?

React multi-step forms where logic has no limits - for any use case

如何安装 @formity/react?

在项目目录运行 npm install @formity/react,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:react(>=16)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。

@formity/react 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@formity/react 支持 ESM 还是 CommonJS?

同时提供 ES Module 与 CommonJS 入口,import 和 require() 都可以使用,打包工具会自动选择合适的版本。

@formity/react 可以商用吗?

@formity/react 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@formity/react 的下载量有多少?

根据 npm 官方下载统计,@formity/react 在 2026/10/16 – 2026/11/14 这 30 天内被下载 12,318 次,日均约 411 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@formity/react 还在维护吗?

最新版本 3.0.0 发布于 2026/06/10(5 个月前);至今共发布 17 个版本,其中过去 12 个月发布了 8 个;首次发布于 2024/12/31。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。