Back to skills
SKILL.md
Wire Doc
ASecurityまだコードに繋がっていない Doc(JSON) を loader(defaults・fail-open)と Res の欄・Resources.reloadRow で配線し、橋渡しテストを最大 3 本書く。JSON を作ったがまだコードから読んでいないとき、「この Doc を繋いで」と言われたときに使う。
- 14 stars
- 0 votes
- 0 copies
- 0 views
- Added December 3, 2026
Security analysis
100/100npx -y skills add ababup1192/flix_game_engine --skill wire-doc --agent claude-codeAre you the author of Wire Doc?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/ababup1192-wire-doc)---
name: wire-doc
description: "まだコードに繋がっていない Doc(JSON) を loader(defaults・fail-open)と Res の欄・Resources.reloadRow で配線し、橋渡しテストを最大 3 本書く。JSON を作ったがまだコードから読んでいないとき、「この Doc を繋いで」と言われたときに使う。"
---
# wire-doc — 未配線 Doc の配線
引数: 未配線の Doc ファイル(例: `assets/foo.kind.json`)。
## 手順
1. 既存の Doc loader を1つ読んで、パターンを確認する
(`fromJson` 系の変換、`defaults`(既定値はコード側)、fail-open —
壊れた入力で落とさず既定値へ落とす)。
2. 同じ形で新しい loader を書く。`<種類>.schema.json` が無ければ書き、
`project.json` の `editor.resources[]` に宣言する。
Doc 本体には必ず `version` を入れる(無いと `bin/fge doc-shape` が止める)。
schema は Studio の **sections 方言**で書く(engine リポの `docs/doc-conventions.md`
「スキーマの書き方」。語彙リファレンス形式では凍結中のエディタのフォームが読めない)。
3. Doc を `Res`(`<ゲーム>/src/Res.flix`)の欄にし、`with*` を足す。保存即反映は `Controls.docTable` に
`Resources.reloadRow(id, path, reload, settle)` の行を 1 つ足す(World に収め直す物が無ければ settle は `(_, w) -> w`)。
Doc を World の欄に置かない(`bin/fge record-wrap` の world-resource が止める)。既存の行をお手本にする。
4. 橋渡しテストを **最大3本** 書く:
- 壊れた JSON → 既定値へ落ちる
- 1 フィールド上書き → その値だけ変わる
- rows があるなら、rows の長さに追随する
期待値は Doc の既定値(コード側の defaults)から導き、数値リテラルを貼らない。
5. `bin/fge check` → `bin/fge test`(macOS と Linux では make check → make test でもよい)で確認して報告する。
Attribution
Related skills
View all in ai-agents →Comments
Loading comments…
Newsletter
Get the weekly list of safe new skills, and the ones we pulled.