[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M78CR3GMK1SMBWCTA199D3FD":3,"skill-same:01M78CR3GMK1SMBWCTA199D3FD":54},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":29,"ownerHtmlUrl":30,"ownerBlogUrl":31,"ownerDescription":32,"updatedAt":33,"install":34,"resources":47},"01M78CR3GMK1SMBWCTA199D3FD","tdd",null,"Test-driven development with vertical tracer-bullet slices. Use when the user wants TDD or red-green-refactor on a vertical slice.","stainless-code\u002Flayers","stainless-code","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F188862219?v=4","01M7826VYMCF2NTQWQZRWQ454T","STAINLESS CODE","01M78CPK4PDPTTAGE6Q5TPCM3M",4,"MIT","https:\u002F\u002Fgithub.com\u002Fstainless-code\u002Flayers\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Ftdd\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: tdd\ndescription: Test-driven development with vertical tracer-bullet slices. Use when the user wants TDD or red-green-refactor on a vertical slice.\n---\n\n# Test-driven development\n\nVertical RED→GREEN cycles — **one behavior per loop**, not horizontal \"all tests then all code\". Aligns with [`tracer-bullets`](..\u002F..\u002Frules\u002Ftracer-bullets.md) and [`verify-after-each-step`](..\u002F..\u002Frules\u002Fverify-after-each-step.md).\n\n## This repo\n\n- Runner split per `docs\u002Farchitecture.md` § Test matrix:\n  - `bun run test` — fans out to every workspace's `src\u002F**\u002F*.test.ts` unit tests (core engine + framework adapter binding, with the framework module mocked or scoped). No DOM.\n  - `bun run test:dom` — `packages\u002F*\u002Ftests-dom\u002F**` (vitest + jsdom + each adapter's testing library) for real-renderer reactivity, outlet\u002Frender, and wrapper behavior.\n- Co-locate tests next to the module (`packages\u002Fcore\u002Fsrc\u002FlayerStack.ts` → `packages\u002Fcore\u002Fsrc\u002FlayerStack.test.ts`).\n- After each GREEN: format\u002Flint\u002Ftypecheck per [`verify-after-each-step`](..\u002F..\u002Frules\u002Fverify-after-each-step.md).\n- Mock at the **framework module seam** in adapter tests (stub `solid-js` \u002F `@angular\u002Fcore` \u002F `preact\u002Fcompat`, or scope via `effectScope`\u002F`createRoot`), never inside `packages\u002Fcore\u002Fsrc\u002F`. See [`PATTERNS.md`](.\u002FPATTERNS.md).\n\n## Workflow\n\n### 1. Planning\n\nConfirm **behaviors** to test (not implementation steps) with the user. Prefer deep modules — small public surface (`LayerClient.open`, `LayerStack`, `layerOptions`), complex internals (phase machine, scope queue, gcTime cache, batched notify).\n\n**Done when:** the behaviors under test are confirmed with the user as observable outcomes through a public seam — not implementation steps.\n\n### 2. Tracer bullet (within slice)\n\n```\nRED:   one test for first behavior → bun test \u003Cfile>   (or test:dom for DOM\u002Frender behavior)\nGREEN: minimal code to pass → re-run\n```\n\n**Done when:** the first behavior has gone RED then GREEN on its touched test file.\n\n### 3. Incremental loop\n\nFor each behavior: RED → GREEN → run affected tests. One test at a time; no speculative features.\n\n**Done when:** every planned behavior has its own RED→GREEN cycle and the affected tests pass.\n\n### 4. Refactor\n\nAfter GREEN — look for duplication, long methods, shallow modules, feature envy. Run `bun test \u003Cfile>` after each step. **Never refactor while RED.** For production polish on a completed slice, [`harden-pr`](..\u002Fharden-pr\u002FSKILL.md) lite may run in parallel with tracer-bullet commits.\n\n**Done when:** duplication and shallow-module smells in the slice are resolved with tests green throughout.\n\n## Checklist per cycle\n\n```\n[ ] Test describes behavior, not implementation\n[ ] Test uses the public seam only (LayerClient.open \u002F LayerStack \u002F layerOptions \u002F useStack)\n[ ] Test would survive an internal refactor\n[ ] Code is minimal for this test\n[ ] bun test (or test:dom) passes on touched file(s)\n```\n\n## Reference\n\n- Good\u002Fbad test patterns + mock boundaries: [`PATTERNS.md`](.\u002FPATTERNS.md)\n- Slice cadence: [`tracer-bullets`](..\u002F..\u002Frules\u002Ftracer-bullets.md) · Verify: [`verify-after-each-step`](..\u002F..\u002Frules\u002Fverify-after-each-step.md)\n","# Test-driven development\n\nVertical RED→GREEN cycles — **one behavior per loop**, not horizontal \"all tests then all code\". Aligns with [`tracer-bullets`](..\u002F..\u002Frules\u002Ftracer-bullets.md) and [`verify-after-each-step`](..\u002F..\u002Frules\u002Fverify-after-each-step.md).\n\n## This repo\n\n- Runner split per `docs\u002Farchitecture.md` § Test matrix:\n  - `bun run test` — fans out to every workspace's `src\u002F**\u002F*.test.ts` unit tests (core engine + framework adapter binding, with the framework module mocked or scoped). No DOM.\n  - `bun run test:dom` — `packages\u002F*\u002Ftests-dom\u002F**` (vitest + jsdom + each adapter's testing library) for real-renderer reactivity, outlet\u002Frender, and wrapper behavior.\n- Co-locate tests next to the module (`packages\u002Fcore\u002Fsrc\u002FlayerStack.ts` → `packages\u002Fcore\u002Fsrc\u002FlayerStack.test.ts`).\n- After each GREEN: format\u002Flint\u002Ftypecheck per [`verify-after-each-step`](..\u002F..\u002Frules\u002Fverify-after-each-step.md).\n- Mock at the **framework module seam** in adapter tests (stub `solid-js` \u002F `@angular\u002Fcore` \u002F `preact\u002Fcompat`, or scope via `effectScope`\u002F`createRoot`), never inside `packages\u002Fcore\u002Fsrc\u002F`. See [`PATTERNS.md`](.\u002FPATTERNS.md).\n\n## Workflow\n\n### 1. Planning\n\nConfirm **behaviors** to test (not implementation steps) with the user. Prefer deep modules — small public surface (`LayerClient.open`, `LayerStack`, `layerOptions`), complex internals (phase machine, scope queue, gcTime cache, batched notify).\n\n**Done when:** the behaviors under test are confirmed with the user as observable outcomes through a public seam — not implementation steps.\n\n### 2. Tracer bullet (within slice)\n\n```\nRED:   one test for first behavior → bun test \u003Cfile>   (or test:dom for DOM\u002Frender behavior)\nGREEN: minimal code to pass → re-run\n```\n\n**Done when:** the first behavior has gone RED then GREEN on its touched test file.\n\n### 3. Incremental loop\n\nFor each behavior: RED → GREEN → run affected tests. One test at a time; no speculative features.\n\n**Done when:** every planned behavior has its own RED→GREEN cycle and the affected tests pass.\n\n### 4. Refactor\n\nAfter GREEN — look for duplication, long methods, shallow modules, feature envy. Run `bun test \u003Cfile>` after each step. **Never refactor while RED.** For production polish on a completed slice, [`harden-pr`](..\u002Fharden-pr\u002FSKILL.md) lite may run in parallel with tracer-bullet commits.\n\n**Done when:** duplication and shallow-module smells in the slice are resolved with tests green throughout.\n\n## Checklist per cycle\n\n```\n[ ] Test describes behavior, not implementation\n[ ] Test uses the public seam only (LayerClient.open \u002F LayerStack \u002F layerOptions \u002F useStack)\n[ ] Test would survive an internal refactor\n[ ] Code is minimal for this test\n[ ] bun test (or test:dom) passes on touched file(s)\n```\n\n## Reference\n\n- Good\u002Fbad test patterns + mock boundaries: [`PATTERNS.md`](.\u002FPATTERNS.md)\n- Slice cadence: [`tracer-bullets`](..\u002F..\u002Frules\u002Ftracer-bullets.md) · Verify: [`verify-after-each-step`](..\u002F..\u002Frules\u002Fverify-after-each-step.md)\n",{"name":5,"description":7},"main","48cb8dae2773a543acd30d0e1af92f9cda91b35a",".agents\u002Fskills\u002Ftdd",0,"https:\u002F\u002Fgithub.com\u002Fstainless-code\u002Flayers","https:\u002F\u002Fstainless-code.com\u002Flayers","https:\u002F\u002Fgithub.com\u002Fstainless-code","https:\u002F\u002Fstainless-code.com\u002F","Open-source tooling for JS\u002FTS and AI agents.","2026-11-01 20:56:20",{"source":8,"skillName":5,"commands":35,"prompt":45,"zipAvailable":46},[36,39,42],{"tool":37,"command":38},"npx","npx skills add stainless-code\u002Flayers --skill tdd",{"tool":40,"command":41},"bunx","bunx skills add stainless-code\u002Flayers --skill tdd",{"tool":43,"command":44},"pnpm","pnpm dlx skills add stainless-code\u002Flayers --skill tdd","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fstainless-code\u002Flayers\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Ftdd\u002FSKILL.md",true,[48],{"path":49,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":52,"sourceHtmlUrl":53},"PATTERNS.md","REFERENCE","参考文档",3909,"https:\u002F\u002Fgithub.com\u002Fstainless-code\u002Flayers\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Ftdd\u002FPATTERNS.md",[55,62,69,76,83,90],{"skillNo":56,"name":57,"nameZh":6,"description":58,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":59,"categories":60,"keywords":61,"publishedAt":19},"01M78CSV0ENFT6T2C1KN4J76HN","vue-layers","Vue adapter for @stainless-code\u002Fvue-layers; open UI from anywhere and manage ordered, named stacks with typed or fire-and-forget `open`","https:\u002F\u002Fgithub.com\u002Fstainless-code\u002Flayers\u002Fblob\u002Fmain\u002Fpackages\u002Fvue\u002Fskills\u002Fvue-layers\u002FSKILL.md",[],[],{"skillNo":63,"name":64,"nameZh":6,"description":65,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":66,"categories":67,"keywords":68,"publishedAt":19},"01M78CSPDPYQ02J822EZNJ0KS6","svelte-layers","Svelte bindings for @stainless-code\u002Fsvelte-layers (runes + stores). Use to open overlay UI imperatively from anywhere, manage ordered named stacks, choose the Svelte 5.7+ runes or Svelte 3+ stores entry, and wire layer context or stack outlets.","https:\u002F\u002Fgithub.com\u002Fstainless-code\u002Flayers\u002Fblob\u002Fmain\u002Fpackages\u002Fsvelte\u002Fskills\u002Fsvelte-layers\u002FSKILL.md",[],[],{"skillNo":70,"name":71,"nameZh":6,"description":72,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":73,"categories":74,"keywords":75,"publishedAt":19},"01M78CSH8P22QAVQWSY6J4D8FQ","solid-layers","SolidJS adapter for @stainless-code\u002Fsolid-layers; open UI from anywhere and manage ordered, named stacks with typed or fire-and-forget `open`","https:\u002F\u002Fgithub.com\u002Fstainless-code\u002Flayers\u002Fblob\u002Fmain\u002Fpackages\u002Fsolid\u002Fskills\u002Fsolid-layers\u002FSKILL.md",[],[],{"skillNo":77,"name":78,"nameZh":6,"description":79,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":80,"categories":81,"keywords":82,"publishedAt":19},"01M78CSCQE83B2VEM4JAW5FAFP","react-layers","React adapter for @stainless-code\u002Freact-layers; open UI from anywhere and manage ordered, named stacks with typed or fire-and-forget `open`","https:\u002F\u002Fgithub.com\u002Fstainless-code\u002Flayers\u002Fblob\u002Fmain\u002Fpackages\u002Freact\u002Fskills\u002Freact-layers\u002FSKILL.md",[],[],{"skillNo":84,"name":85,"nameZh":6,"description":86,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":87,"categories":88,"keywords":89,"publishedAt":19},"01M78CS7RYJ25PK8ASR150R8QS","preact-layers","Preact adapter for @stainless-code\u002Fpreact-layers — use for awaitable confirm flows, singleton toasts, nested drawers, stack subscriptions, and custom layer hosts","https:\u002F\u002Fgithub.com\u002Fstainless-code\u002Flayers\u002Fblob\u002Fmain\u002Fpackages\u002Fpreact\u002Fskills\u002Fpreact-layers\u002FSKILL.md",[],[],{"skillNo":91,"name":92,"nameZh":6,"description":93,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":94,"categories":95,"keywords":96,"publishedAt":19},"01M78CS44RJHSXYT13KZKQPNY3","lit-layers","Lit adapter for @stainless-code\u002Flit-layers; open UI from anywhere and manage ordered, named stacks with typed or fire-and-forget `open` via Reactive Controllers and custom elements","https:\u002F\u002Fgithub.com\u002Fstainless-code\u002Flayers\u002Fblob\u002Fmain\u002Fpackages\u002Flit\u002Fskills\u002Flit-layers\u002FSKILL.md",[],[]]