Skip to content

格式化与代码

GraphQL 格式化工具

免费的 GraphQL 格式化工具。使用 Prettier 的 GraphQL 解析器整理查询、突变、订阅和模式 SDL。粘贴、格式化、复制——完全在浏览器中完成。

Runs in your browser
GraphQL formatter & validator
lines: 0chars: 0size: 0 B
GraphQL · UTF-8 · 2-space indent

编辑注

Understanding · Queries, prettified.

本深度章节目前仅有英文版本。上方的转换工具支持您的语言;长篇说明文章尚未翻译。

常见问题

Quick answers.

Does it format queries or just schemas?

Both. Queries, mutations, subscriptions, fragments and schema SDL all go through the same Prettier parser.

Does it validate against my schema?

No — it's a syntactic formatter only. For schema-aware validation use a dedicated client like GraphiQL or Apollo Studio.

Does it handle multi-operation documents?

Yes — multiple queries or mutations in a single document are formatted and separated consistently.

Is my query sent anywhere?

No — everything runs in your browser.

大家也在搜索

相关工具

More in this room.

查看所有 格式化与代码