@codyswann/lisa 2.111.0 → 2.113.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (164) hide show
  1. package/cdk/package-lisa/package.lisa.json +1 -0
  2. package/dist/core/lisa.d.ts +42 -0
  3. package/dist/core/lisa.d.ts.map +1 -1
  4. package/dist/core/lisa.js +67 -0
  5. package/dist/core/lisa.js.map +1 -1
  6. package/expo/package-lisa/package.lisa.json +1 -0
  7. package/nestjs/package-lisa/package.lisa.json +1 -0
  8. package/package.json +1 -1
  9. package/plugins/lisa/.claude-plugin/plugin.json +1 -1
  10. package/plugins/lisa/.codex-plugin/plugin.json +1 -1
  11. package/plugins/lisa-cdk/.claude-plugin/plugin.json +1 -1
  12. package/plugins/lisa-cdk/.codex-plugin/plugin.json +1 -1
  13. package/plugins/lisa-expo/.claude-plugin/plugin.json +1 -1
  14. package/plugins/lisa-expo/.codex-plugin/plugin.json +1 -1
  15. package/plugins/lisa-expo/.mcp.json +3 -3
  16. package/plugins/lisa-expo/THIRD-PARTY-NOTICES.md +57 -0
  17. package/plugins/lisa-expo/skills/add-app-clip/SKILL.md +280 -0
  18. package/plugins/lisa-expo/skills/add-app-clip/agents/openai.yaml +4 -0
  19. package/plugins/lisa-expo/skills/add-app-clip/references/native-module.md +96 -0
  20. package/plugins/lisa-expo/skills/building-native-ui/SKILL.md +321 -0
  21. package/plugins/lisa-expo/skills/building-native-ui/agents/openai.yaml +4 -0
  22. package/plugins/lisa-expo/skills/building-native-ui/references/animations.md +220 -0
  23. package/plugins/lisa-expo/skills/building-native-ui/references/controls.md +272 -0
  24. package/plugins/lisa-expo/skills/building-native-ui/references/form-sheet.md +253 -0
  25. package/plugins/lisa-expo/skills/building-native-ui/references/gradients.md +106 -0
  26. package/plugins/lisa-expo/skills/building-native-ui/references/icons.md +213 -0
  27. package/plugins/lisa-expo/skills/building-native-ui/references/media.md +198 -0
  28. package/plugins/lisa-expo/skills/building-native-ui/references/route-structure.md +229 -0
  29. package/plugins/lisa-expo/skills/building-native-ui/references/search.md +248 -0
  30. package/plugins/lisa-expo/skills/building-native-ui/references/storage.md +121 -0
  31. package/plugins/lisa-expo/skills/building-native-ui/references/tabs.md +433 -0
  32. package/plugins/lisa-expo/skills/building-native-ui/references/toolbar-and-headers.md +284 -0
  33. package/plugins/lisa-expo/skills/building-native-ui/references/visual-effects.md +197 -0
  34. package/plugins/lisa-expo/skills/building-native-ui/references/webgpu-three.md +605 -0
  35. package/plugins/lisa-expo/skills/building-native-ui/references/zoom-transitions.md +158 -0
  36. package/plugins/lisa-expo/skills/eas-update-insights/SKILL.md +228 -0
  37. package/plugins/lisa-expo/skills/eas-update-insights/agents/openai.yaml +4 -0
  38. package/plugins/lisa-expo/skills/eas-update-insights/references/channel-insights-schema.md +47 -0
  39. package/plugins/lisa-expo/skills/eas-update-insights/references/update-insights-schema.md +69 -0
  40. package/plugins/lisa-expo/skills/expo-api-routes/SKILL.md +369 -0
  41. package/plugins/lisa-expo/skills/expo-api-routes/agents/openai.yaml +4 -0
  42. package/plugins/lisa-expo/skills/expo-brownfield/SKILL.md +54 -0
  43. package/plugins/lisa-expo/skills/expo-brownfield/agents/openai.yaml +4 -0
  44. package/plugins/lisa-expo/skills/expo-brownfield/references/brownfield-integrated.md +526 -0
  45. package/plugins/lisa-expo/skills/expo-brownfield/references/brownfield-isolated.md +402 -0
  46. package/plugins/lisa-expo/skills/expo-brownfield/references/comparison.md +63 -0
  47. package/plugins/lisa-expo/skills/expo-brownfield/references/troubleshooting.md +88 -0
  48. package/plugins/lisa-expo/skills/expo-cicd-workflows/SKILL.md +92 -0
  49. package/plugins/lisa-expo/skills/expo-cicd-workflows/agents/openai.yaml +4 -0
  50. package/plugins/lisa-expo/skills/expo-cicd-workflows/scripts/fetch.js +113 -0
  51. package/plugins/lisa-expo/skills/expo-cicd-workflows/scripts/package.json +11 -0
  52. package/plugins/lisa-expo/skills/expo-cicd-workflows/scripts/validate.js +85 -0
  53. package/plugins/lisa-expo/skills/expo-deployment/SKILL.md +190 -0
  54. package/plugins/lisa-expo/skills/expo-deployment/agents/openai.yaml +4 -0
  55. package/plugins/lisa-expo/skills/expo-deployment/references/app-store-metadata.md +479 -0
  56. package/plugins/lisa-expo/skills/expo-deployment/references/ios-app-store.md +355 -0
  57. package/plugins/lisa-expo/skills/expo-deployment/references/play-store.md +246 -0
  58. package/plugins/lisa-expo/skills/expo-deployment/references/testflight.md +58 -0
  59. package/plugins/lisa-expo/skills/expo-deployment/references/workflows.md +200 -0
  60. package/plugins/lisa-expo/skills/expo-dev-client/SKILL.md +164 -0
  61. package/plugins/lisa-expo/skills/expo-dev-client/agents/openai.yaml +4 -0
  62. package/plugins/lisa-expo/skills/expo-module/SKILL.md +141 -0
  63. package/plugins/lisa-expo/skills/expo-module/agents/openai.yaml +4 -0
  64. package/plugins/lisa-expo/skills/expo-module/references/config-plugin.md +90 -0
  65. package/plugins/lisa-expo/skills/expo-module/references/create-expo-module.md +206 -0
  66. package/plugins/lisa-expo/skills/expo-module/references/lifecycle.md +127 -0
  67. package/plugins/lisa-expo/skills/expo-module/references/module-config.md +48 -0
  68. package/plugins/lisa-expo/skills/expo-module/references/native-module.md +286 -0
  69. package/plugins/lisa-expo/skills/expo-module/references/native-view.md +171 -0
  70. package/plugins/lisa-expo/skills/expo-tailwind-setup/SKILL.md +480 -0
  71. package/plugins/lisa-expo/skills/expo-tailwind-setup/agents/openai.yaml +4 -0
  72. package/plugins/lisa-expo/skills/expo-ui-jetpack-compose/SKILL.md +40 -0
  73. package/plugins/lisa-expo/skills/expo-ui-jetpack-compose/agents/openai.yaml +4 -0
  74. package/plugins/lisa-expo/skills/expo-ui-swift-ui/SKILL.md +39 -0
  75. package/plugins/lisa-expo/skills/expo-ui-swift-ui/agents/openai.yaml +4 -0
  76. package/plugins/lisa-expo/skills/native-data-fetching/SKILL.md +507 -0
  77. package/plugins/lisa-expo/skills/native-data-fetching/agents/openai.yaml +4 -0
  78. package/plugins/lisa-expo/skills/native-data-fetching/references/expo-router-loaders.md +344 -0
  79. package/plugins/lisa-expo/skills/upgrading-expo/SKILL.md +134 -0
  80. package/plugins/lisa-expo/skills/upgrading-expo/agents/openai.yaml +4 -0
  81. package/plugins/lisa-expo/skills/upgrading-expo/references/expo-av-to-audio.md +132 -0
  82. package/plugins/lisa-expo/skills/upgrading-expo/references/expo-av-to-video.md +160 -0
  83. package/plugins/lisa-expo/skills/upgrading-expo/references/native-tabs.md +124 -0
  84. package/plugins/lisa-expo/skills/upgrading-expo/references/new-architecture.md +79 -0
  85. package/plugins/lisa-expo/skills/upgrading-expo/references/react-19.md +79 -0
  86. package/plugins/lisa-expo/skills/upgrading-expo/references/react-compiler.md +59 -0
  87. package/plugins/lisa-expo/skills/upgrading-expo/references/react-navigation-to-expo-router.md +61 -0
  88. package/plugins/lisa-expo/skills/use-dom/SKILL.md +417 -0
  89. package/plugins/lisa-expo/skills/use-dom/agents/openai.yaml +4 -0
  90. package/plugins/lisa-harper-fabric/.claude-plugin/plugin.json +1 -1
  91. package/plugins/lisa-harper-fabric/.codex-plugin/plugin.json +1 -1
  92. package/plugins/lisa-nestjs/.claude-plugin/plugin.json +1 -1
  93. package/plugins/lisa-nestjs/.codex-plugin/plugin.json +1 -1
  94. package/plugins/lisa-openclaw/.claude-plugin/plugin.json +1 -1
  95. package/plugins/lisa-openclaw/.codex-plugin/plugin.json +1 -1
  96. package/plugins/lisa-rails/.claude-plugin/plugin.json +1 -1
  97. package/plugins/lisa-rails/.codex-plugin/plugin.json +1 -1
  98. package/plugins/lisa-typescript/.claude-plugin/plugin.json +1 -1
  99. package/plugins/lisa-typescript/.codex-plugin/plugin.json +1 -1
  100. package/plugins/lisa-wiki/.claude-plugin/plugin.json +1 -1
  101. package/plugins/lisa-wiki/.codex-plugin/plugin.json +1 -1
  102. package/plugins/src/expo/.mcp.json +3 -3
  103. package/plugins/src/expo/THIRD-PARTY-NOTICES.md +57 -0
  104. package/plugins/src/expo/skills/add-app-clip/SKILL.md +280 -0
  105. package/plugins/src/expo/skills/add-app-clip/references/native-module.md +96 -0
  106. package/plugins/src/expo/skills/building-native-ui/SKILL.md +321 -0
  107. package/plugins/src/expo/skills/building-native-ui/references/animations.md +220 -0
  108. package/plugins/src/expo/skills/building-native-ui/references/controls.md +272 -0
  109. package/plugins/src/expo/skills/building-native-ui/references/form-sheet.md +253 -0
  110. package/plugins/src/expo/skills/building-native-ui/references/gradients.md +106 -0
  111. package/plugins/src/expo/skills/building-native-ui/references/icons.md +213 -0
  112. package/plugins/src/expo/skills/building-native-ui/references/media.md +198 -0
  113. package/plugins/src/expo/skills/building-native-ui/references/route-structure.md +229 -0
  114. package/plugins/src/expo/skills/building-native-ui/references/search.md +248 -0
  115. package/plugins/src/expo/skills/building-native-ui/references/storage.md +121 -0
  116. package/plugins/src/expo/skills/building-native-ui/references/tabs.md +433 -0
  117. package/plugins/src/expo/skills/building-native-ui/references/toolbar-and-headers.md +284 -0
  118. package/plugins/src/expo/skills/building-native-ui/references/visual-effects.md +197 -0
  119. package/plugins/src/expo/skills/building-native-ui/references/webgpu-three.md +605 -0
  120. package/plugins/src/expo/skills/building-native-ui/references/zoom-transitions.md +158 -0
  121. package/plugins/src/expo/skills/eas-update-insights/SKILL.md +228 -0
  122. package/plugins/src/expo/skills/eas-update-insights/references/channel-insights-schema.md +47 -0
  123. package/plugins/src/expo/skills/eas-update-insights/references/update-insights-schema.md +69 -0
  124. package/plugins/src/expo/skills/expo-api-routes/SKILL.md +369 -0
  125. package/plugins/src/expo/skills/expo-brownfield/SKILL.md +54 -0
  126. package/plugins/src/expo/skills/expo-brownfield/references/brownfield-integrated.md +526 -0
  127. package/plugins/src/expo/skills/expo-brownfield/references/brownfield-isolated.md +402 -0
  128. package/plugins/src/expo/skills/expo-brownfield/references/comparison.md +63 -0
  129. package/plugins/src/expo/skills/expo-brownfield/references/troubleshooting.md +88 -0
  130. package/plugins/src/expo/skills/expo-cicd-workflows/SKILL.md +92 -0
  131. package/plugins/src/expo/skills/expo-cicd-workflows/scripts/fetch.js +113 -0
  132. package/plugins/src/expo/skills/expo-cicd-workflows/scripts/package.json +11 -0
  133. package/plugins/src/expo/skills/expo-cicd-workflows/scripts/validate.js +85 -0
  134. package/plugins/src/expo/skills/expo-deployment/SKILL.md +190 -0
  135. package/plugins/src/expo/skills/expo-deployment/references/app-store-metadata.md +479 -0
  136. package/plugins/src/expo/skills/expo-deployment/references/ios-app-store.md +355 -0
  137. package/plugins/src/expo/skills/expo-deployment/references/play-store.md +246 -0
  138. package/plugins/src/expo/skills/expo-deployment/references/testflight.md +58 -0
  139. package/plugins/src/expo/skills/expo-deployment/references/workflows.md +200 -0
  140. package/plugins/src/expo/skills/expo-dev-client/SKILL.md +164 -0
  141. package/plugins/src/expo/skills/expo-module/SKILL.md +141 -0
  142. package/plugins/src/expo/skills/expo-module/references/config-plugin.md +90 -0
  143. package/plugins/src/expo/skills/expo-module/references/create-expo-module.md +206 -0
  144. package/plugins/src/expo/skills/expo-module/references/lifecycle.md +127 -0
  145. package/plugins/src/expo/skills/expo-module/references/module-config.md +48 -0
  146. package/plugins/src/expo/skills/expo-module/references/native-module.md +286 -0
  147. package/plugins/src/expo/skills/expo-module/references/native-view.md +171 -0
  148. package/plugins/src/expo/skills/expo-tailwind-setup/SKILL.md +480 -0
  149. package/plugins/src/expo/skills/expo-ui-jetpack-compose/SKILL.md +40 -0
  150. package/plugins/src/expo/skills/expo-ui-swift-ui/SKILL.md +39 -0
  151. package/plugins/src/expo/skills/native-data-fetching/SKILL.md +507 -0
  152. package/plugins/src/expo/skills/native-data-fetching/references/expo-router-loaders.md +344 -0
  153. package/plugins/src/expo/skills/upgrading-expo/SKILL.md +134 -0
  154. package/plugins/src/expo/skills/upgrading-expo/references/expo-av-to-audio.md +132 -0
  155. package/plugins/src/expo/skills/upgrading-expo/references/expo-av-to-video.md +160 -0
  156. package/plugins/src/expo/skills/upgrading-expo/references/native-tabs.md +124 -0
  157. package/plugins/src/expo/skills/upgrading-expo/references/new-architecture.md +79 -0
  158. package/plugins/src/expo/skills/upgrading-expo/references/react-19.md +79 -0
  159. package/plugins/src/expo/skills/upgrading-expo/references/react-compiler.md +59 -0
  160. package/plugins/src/expo/skills/upgrading-expo/references/react-navigation-to-expo-router.md +61 -0
  161. package/plugins/src/expo/skills/use-dom/SKILL.md +417 -0
  162. package/scripts/generate-codex-plugin-artifacts.mjs +7 -2
  163. package/scripts/install-claude-plugins.sh +23 -7
  164. package/typescript/package-lisa/package.lisa.json +2 -0
@@ -0,0 +1,417 @@
1
+ ---
2
+ name: use-dom
3
+ description: Use Expo DOM components to run web code in a webview on native and as-is on web. Migrate web code to native incrementally.
4
+ version: 1.0.0
5
+ license: MIT
6
+ ---
7
+
8
+ ## What are DOM Components?
9
+
10
+ DOM components allow web code to run verbatim in a webview on native platforms while rendering as-is on web. This enables using web-only libraries like `recharts`, `react-syntax-highlighter`, or any React web library in your Expo app without modification.
11
+
12
+ ## When to Use DOM Components
13
+
14
+ Use DOM components when you need:
15
+
16
+ - **Web-only libraries** — Charts (recharts, chart.js), syntax highlighters, rich text editors, or any library that depends on DOM APIs
17
+ - **Migrating web code** — Bring existing React web components to native without rewriting
18
+ - **Complex HTML/CSS layouts** — When CSS features aren't available in React Native
19
+ - **iframes or embeds** — Embedding external content that requires a browser context
20
+ - **Canvas or WebGL** — Web graphics APIs not available natively
21
+
22
+ ## When NOT to Use DOM Components
23
+
24
+ Avoid DOM components when:
25
+
26
+ - **Native performance is critical** — Webviews add overhead
27
+ - **Simple UI** — React Native components are more efficient for basic layouts
28
+ - **Deep native integration** — Use local modules instead for native APIs
29
+ - **Layout routes** — `_layout` files cannot be DOM components
30
+
31
+ ## Basic DOM Component
32
+
33
+ Create a new file with the `'use dom';` directive at the top:
34
+
35
+ ```tsx
36
+ // components/WebChart.tsx
37
+ "use dom";
38
+
39
+ export default function WebChart({
40
+ data,
41
+ }: {
42
+ data: number[];
43
+ dom: import("expo/dom").DOMProps;
44
+ }) {
45
+ return (
46
+ <div style={{ padding: 20 }}>
47
+ <h2>Chart Data</h2>
48
+ <ul>
49
+ {data.map((value, i) => (
50
+ <li key={i}>{value}</li>
51
+ ))}
52
+ </ul>
53
+ </div>
54
+ );
55
+ }
56
+ ```
57
+
58
+ ## Rules for DOM Components
59
+
60
+ 1. **Must have `'use dom';` directive** at the top of the file
61
+ 2. **Single default export** — One React component per file
62
+ 3. **Own file** — Cannot be defined inline or combined with native components
63
+ 4. **Serializable props only** — Strings, numbers, booleans, arrays, plain objects
64
+ 5. **Include CSS in the component file** — DOM components run in isolated context
65
+
66
+ ## The `dom` Prop
67
+
68
+ Every DOM component receives a special `dom` prop for webview configuration. Always type it in your props:
69
+
70
+ ```tsx
71
+ "use dom";
72
+
73
+ interface Props {
74
+ content: string;
75
+ dom: import("expo/dom").DOMProps;
76
+ }
77
+
78
+ export default function MyComponent({ content }: Props) {
79
+ return <div>{content}</div>;
80
+ }
81
+ ```
82
+
83
+ ### Common `dom` Prop Options
84
+
85
+ ```tsx
86
+ // Disable body scrolling
87
+ <DOMComponent dom={{ scrollEnabled: false }} />
88
+
89
+ // Flow under the notch (disable safe area insets)
90
+ <DOMComponent dom={{ contentInsetAdjustmentBehavior: "never" }} />
91
+
92
+ // Control size manually
93
+ <DOMComponent dom={{ style: { width: 300, height: 400 } }} />
94
+
95
+ // Combine options
96
+ <DOMComponent
97
+ dom={{
98
+ scrollEnabled: false,
99
+ contentInsetAdjustmentBehavior: "never",
100
+ style: { width: '100%', height: 500 }
101
+ }}
102
+ />
103
+ ```
104
+
105
+ ## Exposing Native Actions to the Webview
106
+
107
+ Pass async functions as props to expose native functionality to the DOM component:
108
+
109
+ ```tsx
110
+ // app/index.tsx (native)
111
+ import { Alert } from "react-native";
112
+ import DOMComponent from "@/components/dom-component";
113
+
114
+ export default function Screen() {
115
+ return (
116
+ <DOMComponent
117
+ showAlert={async (message: string) => {
118
+ Alert.alert("From Web", message);
119
+ }}
120
+ saveData={async (data: { name: string; value: number }) => {
121
+ // Save to native storage, database, etc.
122
+ console.log("Saving:", data);
123
+ return { success: true };
124
+ }}
125
+ />
126
+ );
127
+ }
128
+ ```
129
+
130
+ ```tsx
131
+ // components/dom-component.tsx
132
+ "use dom";
133
+
134
+ interface Props {
135
+ showAlert: (message: string) => Promise<void>;
136
+ saveData: (data: {
137
+ name: string;
138
+ value: number;
139
+ }) => Promise<{ success: boolean }>;
140
+ dom?: import("expo/dom").DOMProps;
141
+ }
142
+
143
+ export default function DOMComponent({ showAlert, saveData }: Props) {
144
+ const handleClick = async () => {
145
+ await showAlert("Hello from the webview!");
146
+ const result = await saveData({ name: "test", value: 42 });
147
+ console.log("Save result:", result);
148
+ };
149
+
150
+ return <button onClick={handleClick}>Trigger Native Action</button>;
151
+ }
152
+ ```
153
+
154
+ ## Using Web Libraries
155
+
156
+ DOM components can use any web library:
157
+
158
+ ```tsx
159
+ // components/syntax-highlight.tsx
160
+ "use dom";
161
+
162
+ import SyntaxHighlighter from "react-syntax-highlighter";
163
+ import { docco } from "react-syntax-highlighter/dist/esm/styles/hljs";
164
+
165
+ interface Props {
166
+ code: string;
167
+ language: string;
168
+ dom?: import("expo/dom").DOMProps;
169
+ }
170
+
171
+ export default function SyntaxHighlight({ code, language }: Props) {
172
+ return (
173
+ <SyntaxHighlighter language={language} style={docco}>
174
+ {code}
175
+ </SyntaxHighlighter>
176
+ );
177
+ }
178
+ ```
179
+
180
+ ```tsx
181
+ // components/chart.tsx
182
+ "use dom";
183
+
184
+ import {
185
+ LineChart,
186
+ Line,
187
+ XAxis,
188
+ YAxis,
189
+ CartesianGrid,
190
+ Tooltip,
191
+ } from "recharts";
192
+
193
+ interface Props {
194
+ data: Array<{ name: string; value: number }>;
195
+ dom: import("expo/dom").DOMProps;
196
+ }
197
+
198
+ export default function Chart({ data }: Props) {
199
+ return (
200
+ <LineChart width={400} height={300} data={data}>
201
+ <CartesianGrid strokeDasharray="3 3" />
202
+ <XAxis dataKey="name" />
203
+ <YAxis />
204
+ <Tooltip />
205
+ <Line type="monotone" dataKey="value" stroke="#8884d8" />
206
+ </LineChart>
207
+ );
208
+ }
209
+ ```
210
+
211
+ ## CSS in DOM Components
212
+
213
+ CSS imports must be in the DOM component file since they run in isolated context:
214
+
215
+ ```tsx
216
+ // components/styled-component.tsx
217
+ "use dom";
218
+
219
+ import "@/styles.css"; // CSS file in same directory
220
+
221
+ export default function StyledComponent({
222
+ dom,
223
+ }: {
224
+ dom: import("expo/dom").DOMProps;
225
+ }) {
226
+ return (
227
+ <div className="container">
228
+ <h1 className="title">Styled Content</h1>
229
+ </div>
230
+ );
231
+ }
232
+ ```
233
+
234
+ Or use inline styles / CSS-in-JS:
235
+
236
+ ```tsx
237
+ "use dom";
238
+
239
+ const styles = {
240
+ container: {
241
+ padding: 20,
242
+ backgroundColor: "#f0f0f0",
243
+ },
244
+ title: {
245
+ fontSize: 24,
246
+ color: "#333",
247
+ },
248
+ };
249
+
250
+ export default function StyledComponent({
251
+ dom,
252
+ }: {
253
+ dom: import("expo/dom").DOMProps;
254
+ }) {
255
+ return (
256
+ <div style={styles.container}>
257
+ <h1 style={styles.title}>Styled Content</h1>
258
+ </div>
259
+ );
260
+ }
261
+ ```
262
+
263
+ ## Expo Router in DOM Components
264
+
265
+ The expo-router `<Link />` component and router API work inside DOM components:
266
+
267
+ ```tsx
268
+ "use dom";
269
+
270
+ import { Link, useRouter } from "expo-router";
271
+
272
+ export default function Navigation({
273
+ dom,
274
+ }: {
275
+ dom: import("expo/dom").DOMProps;
276
+ }) {
277
+ const router = useRouter();
278
+
279
+ return (
280
+ <nav>
281
+ <Link href="/about">About</Link>
282
+ <button onClick={() => router.push("/settings")}>Settings</button>
283
+ </nav>
284
+ );
285
+ }
286
+ ```
287
+
288
+ ### Router APIs That Require Props
289
+
290
+ These hooks don't work directly in DOM components because they need synchronous access to native routing state:
291
+
292
+ - `useLocalSearchParams()`
293
+ - `useGlobalSearchParams()`
294
+ - `usePathname()`
295
+ - `useSegments()`
296
+ - `useRootNavigation()`
297
+ - `useRootNavigationState()`
298
+
299
+ **Solution:** Read these values in the native parent and pass as props:
300
+
301
+ ```tsx
302
+ // app/[id].tsx (native)
303
+ import { useLocalSearchParams, usePathname } from "expo-router";
304
+ import DOMComponent from "@/components/dom-component";
305
+
306
+ export default function Screen() {
307
+ const { id } = useLocalSearchParams();
308
+ const pathname = usePathname();
309
+
310
+ return <DOMComponent id={id as string} pathname={pathname} />;
311
+ }
312
+ ```
313
+
314
+ ```tsx
315
+ // components/dom-component.tsx
316
+ "use dom";
317
+
318
+ interface Props {
319
+ id: string;
320
+ pathname: string;
321
+ dom?: import("expo/dom").DOMProps;
322
+ }
323
+
324
+ export default function DOMComponent({ id, pathname }: Props) {
325
+ return (
326
+ <div>
327
+ <p>Current ID: {id}</p>
328
+ <p>Current Path: {pathname}</p>
329
+ </div>
330
+ );
331
+ }
332
+ ```
333
+
334
+ ## Detecting DOM Environment
335
+
336
+ Check if code is running in a DOM component:
337
+
338
+ ```tsx
339
+ "use dom";
340
+
341
+ import { IS_DOM } from "expo/dom";
342
+
343
+ export default function Component({
344
+ dom,
345
+ }: {
346
+ dom?: import("expo/dom").DOMProps;
347
+ }) {
348
+ return <div>{IS_DOM ? "Running in DOM component" : "Running natively"}</div>;
349
+ }
350
+ ```
351
+
352
+ ## Assets
353
+
354
+ Prefer requiring assets instead of using the public directory:
355
+
356
+ ```tsx
357
+ "use dom";
358
+
359
+ // Good - bundled with the component
360
+ const logo = require("../assets/logo.png");
361
+
362
+ export default function Component({
363
+ dom,
364
+ }: {
365
+ dom: import("expo/dom").DOMProps;
366
+ }) {
367
+ return <img src={logo} alt="Logo" />;
368
+ }
369
+ ```
370
+
371
+ ## Usage from Native Components
372
+
373
+ Import and use DOM components like regular components:
374
+
375
+ ```tsx
376
+ // app/index.tsx
377
+ import { View, Text } from "react-native";
378
+ import WebChart from "@/components/web-chart";
379
+ import CodeBlock from "@/components/code-block";
380
+
381
+ export default function HomeScreen() {
382
+ return (
383
+ <View style={{ flex: 1 }}>
384
+ <Text>Native content above</Text>
385
+
386
+ <WebChart data={[10, 20, 30, 40, 50]} dom={{ style: { height: 300 } }} />
387
+
388
+ <CodeBlock
389
+ code="const x = 1;"
390
+ language="javascript"
391
+ dom={{ scrollEnabled: true }}
392
+ />
393
+
394
+ <Text>Native content below</Text>
395
+ </View>
396
+ );
397
+ }
398
+ ```
399
+
400
+ ## Platform Behavior
401
+
402
+ | Platform | Behavior |
403
+ | -------- | ----------------------------------- |
404
+ | iOS | Rendered in WKWebView |
405
+ | Android | Rendered in WebView |
406
+ | Web | Rendered as-is (no webview wrapper) |
407
+
408
+ On web, the `dom` prop is ignored since no webview is needed.
409
+
410
+ ## Tips
411
+
412
+ - DOM components hot reload during development
413
+ - Keep DOM components focused — don't put entire screens in webviews
414
+ - Use native components for navigation chrome, DOM components for specialized content
415
+ - Test on all platforms — web rendering may differ slightly from native webviews
416
+ - Large DOM components may impact performance — profile if needed
417
+ - The webview has its own JavaScript context — cannot directly share state with native
@@ -284,12 +284,17 @@ function summarizeDescription(description) {
284
284
  */
285
285
  export function deriveSkillInterface(frontmatter, skillName) {
286
286
  const name = frontmatter?.name?.trim() || skillName;
287
+ // Codex invokes skills by their canonical kebab `$<slug>` token, which is the
288
+ // skill directory name — NOT the (possibly humanized) frontmatter `name`. Some
289
+ // vendored skills (e.g. Expo's) set `name:` to a Title Cased label, which would
290
+ // otherwise yield an invalid handle like `$Expo UI Jetpack Compose`.
291
+ const token = skillName;
287
292
  const description = frontmatter?.description?.trim() || "";
288
293
  const shortDescription = summarizeDescription(description);
289
294
  const starter =
290
295
  shortDescription === ""
291
- ? `Use $${name}`
292
- : `Use $${name}: ${shortDescription}.`;
296
+ ? `Use $${token}`
297
+ : `Use $${token}: ${shortDescription}.`;
293
298
  return {
294
299
  display_name: humanizeName(name),
295
300
  short_description: shortDescription,
@@ -16,13 +16,29 @@ if [ "$PACKAGE_NAME" = "@codyswann/lisa" ]; then exit 0; fi
16
16
 
17
17
  cd "$PROJECT_ROOT"
18
18
 
19
- # NOTE: Template application is intentionally NOT run during postinstall.
20
- # Running the full apply here caused child-stack template conflicts in CI:
21
- # the TypeScript templates would overwrite Expo/CDK-specific configs (tsconfig.json,
22
- # eslint.config.ts), and if the process failed mid-way, the child stack's templates
23
- # never restored the correct versions. Template application should only happen via
24
- # explicit `lisa:update` (npx @codyswann/lisa@latest .) or the project's own
25
- # postinstall script (defaults.scripts.postinstall in package.lisa.json).
19
+ # Apply Lisa templates non-interactively (init when missing, update when present),
20
+ # EXCEPT in CI. --skip-git-check bypasses the dirty working directory check since
21
+ # package.json and the lockfile are always uncommitted during postinstall.
22
+ #
23
+ # CI skip: matches the established Lisa philosophy (see ensure-lisa-postinstall
24
+ # migration and tests/unit/config/postinstall-ci-guard.test.ts) in CI the
25
+ # committed tree is the source of truth and the PR diff is the drift detector, so
26
+ # silently re-applying templates during `bun install --frozen-lockfile` would
27
+ # churn package.json/lockfile and mask drift. Local installs self-heal; CI does not.
28
+ #
29
+ # Crash safety (local path): pre-#318 this could leave a half-applied tree — the
30
+ # TypeScript phase wrote tsconfig.json/eslint.config.ts and a child stack
31
+ # (expo/cdk/nestjs) phase was expected to overwrite them; if the package manager
32
+ # killed the lifecycle process between those phases, the child stack was left with
33
+ # the TypeScript versions. The apply now pre-resolves copy-overwrite ownership so
34
+ # each path is written exactly once by its most-specific stack — there is no
35
+ # intermediate clobbered state to be interrupted in. See src/core/lisa.ts
36
+ # loadCopyOverwriteOwnership.
37
+ if [ -z "${CI:-}" ]; then
38
+ if ! node "$LISA_DIR/dist/index.js" --yes --skip-git-check "$PROJECT_ROOT"; then
39
+ echo "⚠️ Warning: Lisa template application failed. Migration may be incomplete." >&2
40
+ fi
41
+ fi
26
42
 
27
43
  # Strip only hook entries that reference deleted .claude/hooks/*.sh scripts
28
44
  # (hooks moved to plugin.json; file-path hooks would produce "No such file or directory" errors).
@@ -18,6 +18,7 @@
18
18
  "prepare": "node -e \"if (process.env.INIT_CWD && process.env.INIT_CWD.includes('.serverless')) { process.exit(0); }\" && husky install || true"
19
19
  },
20
20
  "devDependencies": {
21
+ "@codyswann/lisa": "^2.106.0",
21
22
  "eslint-plugin-oxlint": "^1.62.0",
22
23
  "oxlint": "^1.62.0",
23
24
  "oxlint-tsgolint": "^0.22.1"
@@ -36,6 +37,7 @@
36
37
  "defaults": {
37
38
  "scripts": {
38
39
  "build": "tsc",
40
+ "postinstall": "[ -n \"$CI\" ] || node node_modules/@codyswann/lisa/dist/index.js --yes --skip-git-check . 2>/dev/null || true",
39
41
  "test:integration": "vitest run tests/integration --passWithNoTests"
40
42
  },
41
43
  "engines": {