Flow

react/react/.claude/skills/flow

作者 reactb618bbb44226无许可证250K 个星标收录于 2026年10月8日更新于 2026年10月8日仓库昨天更新

Use when you need to run Flow type checking, or when seeing Flow type errors in React code.

AI 生成的概览

对 React 代码运行 Flow 类型检查,并报告带文件位置的类型错误。

功能
该技能指导代理通过 yarn 命令运行 Flow 类型检查,并选择渲染器,例如 dom-node、dom-browser、native 或 fabric。它会报告类型错误及其文件位置,并可运行较慢的全面检查。它还列出了常见错误,包括未指定渲染器、忽略抑制注释以及缺少类型导入。
适用场景
当你需要运行 Flow 类型检查,或 React 代码中出现 Flow 类型错误时使用。它面向已使用 Flow 和 yarn 脚本的项目。
运行要求
需要已配置 Flow 并具有 yarn flow、yarn flow-ci 等 yarn 脚本的项目。该技能不附带脚本,仅为说明文档。

Flow Type Checking

Arguments:

  • $ARGUMENTS: Renderer to check (default: dom-node)

Renderers

RendererWhen to Use
dom-nodeDefault, recommended for most changes
dom-browserBrowser-specific DOM code
nativeReact Native
fabricReact Native Fabric

Instructions

  1. Run yarn flow $ARGUMENTS (use dom-node if no argument)
  2. Report type errors with file locations
  3. For comprehensive checking (slow), use yarn flow-ci

Common Mistakes

  • Running without a renderer - Always specify or use default dom-node
  • Ignoring suppressions - Check if $FlowFixMe comments are masking real issues
  • Missing type imports - Ensure types are imported from the correct package

来源与署名

来源:react/react位于.claude/skills/flow提交b618bbb

许可证: 无许可证

内容归原作者所有。SourceWeft 从公开仓库中收录这些内容。

举报或申请下架