You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .kilocode/skills/waveenv/SKILL.md
+54-61Lines changed: 54 additions & 61 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -23,82 +23,75 @@ Create a narrowing whenever you are writing a component (or group of components)
23
23
24
24
## File Location
25
25
26
-
-**Separate file** (preferred for shared/complex envs): name it `<feature>env.ts` next to the component, e.g. [`frontend/app/block/blockenv.ts`](frontend/app/block/blockenv.ts).
27
-
-**Inline** (acceptable for small, single-file components): export the type directly from the component file, e.g. `WidgetsEnv` in [`frontend/app/workspace/widgets.tsx`](frontend/app/workspace/widgets.tsx:23).
26
+
-**Separate file** (preferred for shared/complex envs): name it `<feature>env.ts` next to the component, e.g. `frontend/app/block/blockenv.ts`.
27
+
-**Inline** (acceptable for small, single-file components): export the type directly from the component file, e.g. `WidgetsEnv` in `frontend/app/workspace/widgets.tsx`.
28
28
29
29
## Imports Required
30
30
31
31
```ts
32
32
import {
33
-
BlockMetaKeyAtomFnType,// only if you use getBlockMetaKeyAtom
34
-
ConnConfigKeyAtomFnType,// only if you use getConnConfigKeyAtom
35
-
SettingsKeyAtomFnType,// only if you use getSettingsKeyAtom
36
-
WaveEnv,
37
-
WaveEnvSubset,
33
+
BlockMetaKeyAtomFnType, // only if you use getBlockMetaKeyAtom
34
+
ConnConfigKeyAtomFnType, // only if you use getConnConfigKeyAtom
35
+
SettingsKeyAtomFnType, // only if you use getSettingsKeyAtom
36
+
WaveEnv,
37
+
WaveEnvSubset,
38
38
} from"@/app/waveenv/waveenv";
39
39
```
40
40
41
41
## The Shape
42
42
43
43
```ts
44
44
exporttypeMyEnv=WaveEnvSubset<{
45
-
// --- Simple WaveEnv properties ---
46
-
// Copy the type verbatim from WaveEnv with WaveEnv["key"] syntax.
47
-
isDev:WaveEnv["isDev"];
48
-
createBlock:WaveEnv["createBlock"];
49
-
showContextMenu:WaveEnv["showContextMenu"];
50
-
platform:WaveEnv["platform"];
51
-
52
-
// --- electron: list only the methods you call ---
0 commit comments