dimitriremoiville/cc-mobile/compose-ui
Claude Code and agent skill by dimitriremoiville/cc-mobile
- community
Checking that the SKILL.md file is still in the repository.
Project-specific Compose conventions — the Route/Screen split, `UiState` / `UiEvent` shape, Figma-MCP-to-`MaterialTheme` translation, and the hard-nos this project enforces. Load whenever writing or editing any `@Composable` in this codebase. Navigation destinations and route plumbing live in `navigation-compose` — load that one for any nav-graph or typed-route work.
Install
npx vskill@latest install dimitriremoiville/cc-mobile/compose-uiSKILL.md
The same SKILL.md was published earlier as dimitriremoiville/cc-mobile/compose-ui.
Compose UI (project delta)
For Compose fundamentals — state hoisting, Modifier ordering, LazyColumn keys, @Preview, recomposition hygiene, derivedStateOf, stability — read the official Compose state guide and Google's published `android/skills/jetpack-compose/*` skills (adaptive layouts, theming, View-to-Compose migration). This file documents only where this project's conventions add to or override those defaults.
When this applies
Jetpack Compose only. On an existing app:
- View-based UI (
res/layout/*.xml,findViewById,binding.,Fragmentsetup) → don't push Compose patterns. The Route/Screen split,collectAsStateWithLifecycle,Modifier-first conventions are Compose-only. - Mixed Compose + View (
ComposeViewinside an XML layout, or Compose host fragments) → apply this skill to the@Composableparts only; let the View parts follow their own conventions.
Pulling design specs from Figma
The plugin declares Figma's official MCP server (.mcp.json → figma, https://mcp.figma.com/mcp, OAuth — no API key in the plugin). If the user supplies a Figma URL when asking for a screen or component, pull layout / typography / color / spacing details from the file before generating Compose code. First call triggers a browser OAuth prompt; nothing to configure beyond that.
Map Figma tokens onto MaterialTheme.colorScheme / typography / shapes. Don't paste raw hex/px values into composables — translate to the theme.
Route + Screen split (project rule)
Every screen is two functions: a stateful Route that owns the ViewModel, and a stateless Screen that renders state and surfaces callbacks. The Route is the only place hiltViewModel() is called; everything below the Screen receives state + lambdas as parameters.
The Screen is what @Preview and Compose UI tests drive — no Hilt setup required. The Route's job is wiring; the Screen's job is rendering.
UiState and UiEvent shape
State is always a sealed type with explicit Loading / Error / Success branches by default:
One-off effects (navigation, snackbars, toasts) are not state — they're events emitted through a Channel<UiEvent> and collected once in the Route:
StateFlow for state, Channel for events. SharedFlow only when you actually need replay.
Theming
- Colors come from
MaterialTheme.colorScheme.*. No hex literals in `@Composable` code — they live in the theme files only. - Typography tokens are defined in
Type.ktand consumed asMaterialTheme.typography.bodyLargeetc. - Shapes as
MaterialTheme.shapes.mediumetc.
When extracting from Figma, define the token in the theme, then reference it from composables.
Accessibility
The full accessibility checklist lives in the android-accessibility skill. The minimum the reviewer flags here:
- Every
Iconwithout adjacent text gets acontentDescription(ornull, explicit). - Interactive elements ≥ 48dp tap target.
Hard nos
- No `LiveData` in new code — use
StateFlow. - No `collectAsState()` for ViewModel state —
collectAsStateWithLifecycle()only. - No `hiltViewModel()` outside the Route. Never inside a child composable, never passed down as a parameter.
- No network or DB calls inside a `@Composable` or any
LaunchedEffectthat reaches around the ViewModel. - No hex literals in composables. Always go through
MaterialTheme.*(see Theming). - No `@Composable` longer than ~60-80 lines. Extract children when concerns mix (layout + stateful behaviour + event handling) or nesting exceeds 3 levels. Lines alone aren't the rule; readability is.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingplugins/cc-mobile-android/skills/compose-ui/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/dimitriremoiville/cc-mobile/compose-ui)