[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7A14GKQNTRAC4JM99PAK3P4":3,"skill-same:01M7A14GKQNTRAC4JM99PAK3P4":61},{"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":29,"ownerDescription":31,"updatedAt":32,"install":33,"resources":46},"01M7A14GKQNTRAC4JM99PAK3P4","compose-state-and-effects",null,"Use when writing or reviewing Jetpack Compose state ownership, remember state, state hoisting, screen state holders, LaunchedEffect, DisposableEffect, SideEffect, Flow collection, navigation, snackbar, analytics, or focus requests.","openvetta\u002Fopen-vetta","openvetta","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F310452651?v=4","01M7A143Q6S7A6WZEJYZN5TTYM","Open Vetta","01M7A143R600YHMC29N957HQP8",299,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fcompose-state-and-effects\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: compose-state-and-effects\ndescription: Use when writing or reviewing Jetpack Compose state ownership, remember state, state hoisting, screen state holders, LaunchedEffect, DisposableEffect, SideEffect, Flow collection, navigation, snackbar, analytics, or focus requests.\n---\n\n# Compose state and effects\n\n## Core principle\n\nGive every piece of UI state one lowest responsible owner, then run imperative\nwork through the effect whose lifecycle follows that owner. Composition renders;\nstate and effects make rendering change safely.\n\nA screen-ownership review is incomplete until it names the plain, previewable\ncontent composable that receives immutable state and event callbacks separately\nfrom app wiring and composition-owned runtime objects.\n\n## Procedure\n\n1. Establish the requested scope and visible behavioral requirements. Treat an\n   ownership change as a finding only when code or task evidence shows a\n   lifecycle, testability, business, or coordination need.\n2. Inventory mutable UI state, app state, event streams, app dependencies, and\n   imperative work in the affected screen or component.\n3. Place each state value at its lowest necessary owner: local UI state,\n   hoisted state, a plain UI state holder, or a screen state holder.\n4. For a screen boundary, keep durable data and intents in the wiring owner,\n   Compose runtime objects in composition or a plain UI state holder, and\n   rendering in a previewable content composable that takes immutable state\n   and callbacks. Read [State hoisting](references\u002Fstate-hoisting.md) for the\n   implementation shape; naming only state and intents is not that boundary.\n   Keep this content callable with sample state and callbacks; an `@Preview`\n   wrapper is optional and is not required for the state-driven boundary.\n   Before adding it, confirm the module declares its tooling; do not assume\n   Compose runtime or UI dependencies provide it. Respect the task's file\n   scope: do not add tooling or change build files unless authorized. If\n   Preview tooling is needed but unavailable within scope, omit the wrapper\n   and report the setup gap.\n5. Choose an effect API whose lifecycle matches the work, and key it by the\n   semantic input that should restart or dispose it.\n6. Load the focused reference for every material concern below. Do not use a\n   reference merely because its topic is adjacent.\n7. Route frame-rate reads, cross-phase back-writing, and\n   `@ReadOnlyComposable` contracts to [Compose performance](..\u002Fcompose-performance\u002FSKILL.md).\n   For that contract, distinguish a read of snapshot `State.value` from an\n   operation that changes the composer; the state read alone is not a violation.\n8. Before responding to a screen-ownership review, verify all three screen\n   seams in step 4 when visible code needs them.\n9. Finish when every state value has one owner, every effect has a justified\n   lifecycle and key, and the UI can be previewed and tested without app\n   dependencies. For review-only work, report no change when no evidence-backed\n   issue remains; do not invent product requirements.\n\n## Topic router\n\n| Signal | Read |\n|---|---|\n| Bare local `var`, `remember { mutableStateOf(...) }`, state lists\u002Fmaps, or reset state | [Local state](references\u002Flocal-state.md) |\n| State shared by siblings, UI state holders, ViewModel\u002Fcomponent wiring, or previewable screen boundaries | [State hoisting](references\u002Fstate-hoisting.md) |\n| `LaunchedEffect`, `DisposableEffect`, `SideEffect`, `snapshotFlow`, `rememberCoroutineScope`, `rememberUpdatedState`, `produceState`, imperative `requestFocus`, callbacks, event Flow collection, snackbar, navigation, or analytics | [Side effects](references\u002Fside-effects.md) |\n| Focus ownership and keyboard\u002FTV\u002FD-pad behavior | [Compose focus navigation](..\u002Fcompose-focus-navigation\u002FSKILL.md) |\n| Tests or previews for the resulting UI contract | [Compose UI testing patterns](..\u002Fcompose-ui-testing-patterns\u002FSKILL.md) |\n","# Compose state and effects\n\n## Core principle\n\nGive every piece of UI state one lowest responsible owner, then run imperative\nwork through the effect whose lifecycle follows that owner. Composition renders;\nstate and effects make rendering change safely.\n\nA screen-ownership review is incomplete until it names the plain, previewable\ncontent composable that receives immutable state and event callbacks separately\nfrom app wiring and composition-owned runtime objects.\n\n## Procedure\n\n1. Establish the requested scope and visible behavioral requirements. Treat an\n   ownership change as a finding only when code or task evidence shows a\n   lifecycle, testability, business, or coordination need.\n2. Inventory mutable UI state, app state, event streams, app dependencies, and\n   imperative work in the affected screen or component.\n3. Place each state value at its lowest necessary owner: local UI state,\n   hoisted state, a plain UI state holder, or a screen state holder.\n4. For a screen boundary, keep durable data and intents in the wiring owner,\n   Compose runtime objects in composition or a plain UI state holder, and\n   rendering in a previewable content composable that takes immutable state\n   and callbacks. Read [State hoisting](references\u002Fstate-hoisting.md) for the\n   implementation shape; naming only state and intents is not that boundary.\n   Keep this content callable with sample state and callbacks; an `@Preview`\n   wrapper is optional and is not required for the state-driven boundary.\n   Before adding it, confirm the module declares its tooling; do not assume\n   Compose runtime or UI dependencies provide it. Respect the task's file\n   scope: do not add tooling or change build files unless authorized. If\n   Preview tooling is needed but unavailable within scope, omit the wrapper\n   and report the setup gap.\n5. Choose an effect API whose lifecycle matches the work, and key it by the\n   semantic input that should restart or dispose it.\n6. Load the focused reference for every material concern below. Do not use a\n   reference merely because its topic is adjacent.\n7. Route frame-rate reads, cross-phase back-writing, and\n   `@ReadOnlyComposable` contracts to [Compose performance](..\u002Fcompose-performance\u002FSKILL.md).\n   For that contract, distinguish a read of snapshot `State.value` from an\n   operation that changes the composer; the state read alone is not a violation.\n8. Before responding to a screen-ownership review, verify all three screen\n   seams in step 4 when visible code needs them.\n9. Finish when every state value has one owner, every effect has a justified\n   lifecycle and key, and the UI can be previewed and tested without app\n   dependencies. For review-only work, report no change when no evidence-backed\n   issue remains; do not invent product requirements.\n\n## Topic router\n\n| Signal | Read |\n|---|---|\n| Bare local `var`, `remember { mutableStateOf(...) }`, state lists\u002Fmaps, or reset state | [Local state](references\u002Flocal-state.md) |\n| State shared by siblings, UI state holders, ViewModel\u002Fcomponent wiring, or previewable screen boundaries | [State hoisting](references\u002Fstate-hoisting.md) |\n| `LaunchedEffect`, `DisposableEffect`, `SideEffect`, `snapshotFlow`, `rememberCoroutineScope`, `rememberUpdatedState`, `produceState`, imperative `requestFocus`, callbacks, event Flow collection, snackbar, navigation, or analytics | [Side effects](references\u002Fside-effects.md) |\n| Focus ownership and keyboard\u002FTV\u002FD-pad behavior | [Compose focus navigation](..\u002Fcompose-focus-navigation\u002FSKILL.md) |\n| Tests or previews for the resulting UI contract | [Compose UI testing patterns](..\u002Fcompose-ui-testing-patterns\u002FSKILL.md) |\n",{"name":5,"description":7},"main","a4aeb31ba1b80e809bf4ddc0406287429275e34e",".agents\u002Fskills\u002Fcompose-state-and-effects",50,"https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta","https:\u002F\u002Fwww.openvetta.com","https:\u002F\u002Fgithub.com\u002Fopenvetta","Open-source, local-first AI agent for coding and real work.","2026-11-14 00:11:40",{"source":8,"skillName":5,"commands":34,"prompt":44,"zipAvailable":45},[35,38,41],{"tool":36,"command":37},"npx","npx skills add openvetta\u002Fopen-vetta --skill compose-state-and-effects",{"tool":39,"command":40},"bunx","bunx skills add openvetta\u002Fopen-vetta --skill compose-state-and-effects",{"tool":42,"command":43},"pnpm","pnpm dlx skills add openvetta\u002Fopen-vetta --skill compose-state-and-effects","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fcompose-state-and-effects\u002FSKILL.md",true,[47,53,57],{"path":48,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":51,"sourceHtmlUrl":52},"references\u002Flocal-state.md","REFERENCE","参考文档",1854,"https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fcompose-state-and-effects\u002Freferences\u002Flocal-state.md",{"path":54,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":55,"sourceHtmlUrl":56},"references\u002Fside-effects.md",2692,"https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fcompose-state-and-effects\u002Freferences\u002Fside-effects.md",{"path":58,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":59,"sourceHtmlUrl":60},"references\u002Fstate-hoisting.md",2984,"https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fcompose-state-and-effects\u002Freferences\u002Fstate-hoisting.md",[62,69,76,83,90,97],{"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},"01M7A1CADNDSES6MRAARA1WXMB","publish-ability","Publish a skill, MCP server, plugin, or bundle to the Vetta ability marketplace. Use when the user asks to upload\u002Fpublish\u002Fsubmit an ability, put a plugin on the marketplace, share a skill with other users, or migrate an existing package into Vetta.","https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002Fpackages\u002Fskill-presets\u002Fpublish-ability\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},"01M7A1C5VD4NEZHMZMCXF8J47M","install-ability","在本机 Vetta 中安装能力——插件（plugin）、Skill 与 MCP 服务器。用户说「装一个插件 \u002F install plugin \u002F 从能力市场安装 \u002F 加一个 MCP server \u002F 配置 MCP \u002F 装个 skill」，或插件装完没生效、需要 reload、pending 版本没应用时使用。不用于安装 npm 依赖、IDE 插件、浏览器扩展，也不用于开发插件（那是 plugin-workbench）或创作 Skill（那是 create-skill）。","https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002Fpackages\u002Fskill-presets\u002Finstall-ability\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},"01M7A1C0414EPE2EWRD5B26HWC","create-skill","Create or update Vetta-compatible Agent Skills. Use when the user asks to create a skill, add a SKILL.md workflow, register a skill in skills-manifest.json, package a skill in a Vetta plugin, or add a built-in Vetta skill preset.","https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002Fpackages\u002Fskill-presets\u002Fcreate-skill\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},"01M7A1BNBJ5XJKWND9XFJKP0FX","vetta-ui-design","Build and edit design documents (.vetd) on the Vetta design canvas — app screens, landing pages, slides, posters, infographics. Use when the user asks for a UI design, mockup, screen, deck, or poster, or attaches a design frame\u002Felement from the canvas. Frames are real React (TSX) routes, not pictures. Do NOT use for ordinary front-end work in the user's own codebase — building, styling or reworking pages of a real app is that repo's job, and none of the vetd_* tools or canvas rules here apply to it.","https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002Fpackages\u002Fplugins\u002Fpresets\u002Fvetta-ui-design\u002Fagent\u002Fskills\u002Fvetta-ui-design\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},"01M7A1BFJSH10EZFJ4J56M8E2Z","remotion-video","Create, modify, and render Remotion React video projects in the current Vetta conversation workspace. Use for requests to make programmatic videos, motion graphics, animated explainers, social videos, data videos, or to edit an existing Remotion composition and export it as MP4.","https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002Fpackages\u002Fplugins\u002Fpresets\u002Fremotion-renderer\u002Fagent\u002Fskills\u002Fremotion-video\u002FSKILL.md",[],[],{"skillNo":98,"name":99,"nameZh":6,"description":100,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":101,"categories":102,"keywords":103,"publishedAt":19},"01M7A1B8WD792ETC0XYJV8GNNB","plugin-workbench","Create, implement, build, pack, install, reload, and manage Vetta desktop plugins for non-developers. Use whenever the user wants a Vetta plugin, plugin scaffolding, apply a `.vettapkg` package to Vetta, edit plugin.json name\u002FguidingWords, or debug plugin load\u002Finstall. Requires the Plugin Workbench input-bar toggle (hard isolation). The plugin handbook ships inside the project's own @vetta-org\u002Fplugin-sdk; locate it with the bundled CLI's docs command.","https:\u002F\u002Fgithub.com\u002Fopenvetta\u002Fopen-vetta\u002Fblob\u002Fmain\u002Fpackages\u002Fplugins\u002Fpresets\u002Fplugin-workbench\u002Fagent\u002Fskills\u002Fplugin-workbench\u002FSKILL.md",[],[]]