Skip to main content
在 Manus 中运行任何 Skill
一键导入

sanity-schema-lint-suppressions

星标16
分支7
更新时间2026年7月7日 16:25

How to recognise, fix, and suppress false-positive warnings from the @sanity-labs/eslint-plugin schema rules — especially the name-based `sanity/schema-heading-level-in-schema` heuristic. Covers where the disable comment must go (above the `defineType` call, not the field), why TypeScript changes cannot silence these rules, the `Rule.custom<T>` generic constraint, and which Portable Text patterns are NOT affected. Use when an ESLint warning from `@sanity-labs/eslint-plugin` looks wrong, when a Sanity schema field is flagged for "appears to store heading levels", when adding a field whose name ends in `Level` / `h1`–`h6`, or when wiring `Rule.custom` validators on enum-typed string fields.

安装

用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。

SKILL.md
readonly