@mandujs/core 0.18.22 → 0.19.2

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 (91) hide show
  1. package/README.ko.md +0 -14
  2. package/package.json +4 -1
  3. package/src/brain/architecture/analyzer.ts +4 -4
  4. package/src/brain/doctor/analyzer.ts +18 -14
  5. package/src/bundler/build.test.ts +127 -0
  6. package/src/bundler/build.ts +291 -113
  7. package/src/bundler/css.ts +20 -5
  8. package/src/bundler/dev.ts +55 -2
  9. package/src/bundler/prerender.ts +195 -0
  10. package/src/change/snapshot.ts +4 -23
  11. package/src/change/types.ts +2 -3
  12. package/src/client/Form.tsx +105 -0
  13. package/src/client/__tests__/use-sse.test.ts +153 -0
  14. package/src/client/hooks.ts +105 -6
  15. package/src/client/index.ts +35 -6
  16. package/src/client/router.ts +670 -433
  17. package/src/client/rpc.ts +140 -0
  18. package/src/client/runtime.ts +24 -21
  19. package/src/client/use-fetch.ts +239 -0
  20. package/src/client/use-head.ts +197 -0
  21. package/src/client/use-sse.ts +378 -0
  22. package/src/components/Image.tsx +162 -0
  23. package/src/config/mandu.ts +5 -0
  24. package/src/config/validate.ts +34 -0
  25. package/src/content/index.ts +5 -1
  26. package/src/devtools/client/catchers/error-catcher.ts +17 -0
  27. package/src/devtools/client/catchers/network-proxy.ts +390 -367
  28. package/src/devtools/client/components/kitchen-root.tsx +479 -467
  29. package/src/devtools/client/components/panel/diff-viewer.tsx +219 -0
  30. package/src/devtools/client/components/panel/guard-panel.tsx +374 -244
  31. package/src/devtools/client/components/panel/index.ts +45 -32
  32. package/src/devtools/client/components/panel/panel-container.tsx +332 -312
  33. package/src/devtools/client/components/panel/preview-panel.tsx +188 -0
  34. package/src/devtools/client/state-manager.ts +535 -478
  35. package/src/devtools/design-tokens.ts +265 -264
  36. package/src/devtools/types.ts +345 -319
  37. package/src/filling/context.ts +65 -0
  38. package/src/filling/filling.ts +336 -14
  39. package/src/filling/index.ts +5 -1
  40. package/src/filling/session.ts +216 -0
  41. package/src/filling/ws.ts +78 -0
  42. package/src/generator/generate.ts +2 -2
  43. package/src/guard/auto-correct.ts +0 -29
  44. package/src/guard/check.ts +14 -31
  45. package/src/guard/presets/index.ts +296 -294
  46. package/src/guard/rules.ts +15 -19
  47. package/src/guard/validator.ts +834 -834
  48. package/src/index.ts +5 -1
  49. package/src/island/index.ts +373 -304
  50. package/src/kitchen/api/contract-api.ts +225 -0
  51. package/src/kitchen/api/diff-parser.ts +108 -0
  52. package/src/kitchen/api/file-api.ts +273 -0
  53. package/src/kitchen/api/guard-api.ts +83 -0
  54. package/src/kitchen/api/guard-decisions.ts +100 -0
  55. package/src/kitchen/api/routes-api.ts +50 -0
  56. package/src/kitchen/index.ts +21 -0
  57. package/src/kitchen/kitchen-handler.ts +256 -0
  58. package/src/kitchen/kitchen-ui.ts +1732 -0
  59. package/src/kitchen/stream/activity-sse.ts +145 -0
  60. package/src/kitchen/stream/file-tailer.ts +99 -0
  61. package/src/middleware/compress.ts +62 -0
  62. package/src/middleware/cors.ts +47 -0
  63. package/src/middleware/index.ts +10 -0
  64. package/src/middleware/jwt.ts +134 -0
  65. package/src/middleware/logger.ts +58 -0
  66. package/src/middleware/timeout.ts +55 -0
  67. package/src/paths.ts +0 -4
  68. package/src/plugins/hooks.ts +64 -0
  69. package/src/plugins/index.ts +3 -0
  70. package/src/plugins/types.ts +5 -0
  71. package/src/report/build.ts +0 -6
  72. package/src/resource/__tests__/backward-compat.test.ts +0 -1
  73. package/src/router/fs-patterns.ts +11 -1
  74. package/src/router/fs-routes.ts +78 -14
  75. package/src/router/fs-scanner.ts +2 -2
  76. package/src/router/fs-types.ts +2 -1
  77. package/src/runtime/adapter-bun.ts +62 -0
  78. package/src/runtime/adapter.ts +47 -0
  79. package/src/runtime/cache.ts +310 -0
  80. package/src/runtime/handler.ts +65 -0
  81. package/src/runtime/image-handler.ts +195 -0
  82. package/src/runtime/index.ts +12 -0
  83. package/src/runtime/middleware.ts +263 -0
  84. package/src/runtime/server.ts +686 -92
  85. package/src/runtime/ssr.ts +55 -29
  86. package/src/runtime/streaming-ssr.ts +106 -82
  87. package/src/spec/index.ts +0 -1
  88. package/src/spec/schema.ts +1 -0
  89. package/src/testing/index.ts +144 -0
  90. package/src/watcher/watcher.ts +27 -1
  91. package/src/spec/lock.ts +0 -56
@@ -1,294 +1,296 @@
1
- /**
2
- * Guard Presets
3
- *
4
- * 아키텍처 프리셋 모음
5
- */
6
-
7
- import type { GuardPreset, PresetDefinition } from "../types";
8
- import { fsdPreset, FSD_HIERARCHY } from "./fsd";
9
- import { cleanPreset, CLEAN_HIERARCHY } from "./clean";
10
- import { hexagonalPreset, HEXAGONAL_HIERARCHY } from "./hexagonal";
11
- import { atomicPreset, ATOMIC_HIERARCHY } from "./atomic";
12
- import { cqrsPreset, CQRS_HIERARCHY } from "./cqrs";
13
-
14
- // Re-export types
15
- export type { GuardPreset, PresetDefinition } from "../types";
16
-
17
- // Re-export
18
- export { fsdPreset, FSD_HIERARCHY } from "./fsd";
19
- export { cleanPreset, CLEAN_HIERARCHY } from "./clean";
20
- export { hexagonalPreset, HEXAGONAL_HIERARCHY } from "./hexagonal";
21
- export { atomicPreset, ATOMIC_HIERARCHY } from "./atomic";
22
- export { cqrsPreset, CQRS_HIERARCHY } from "./cqrs";
23
-
24
- /**
25
- * Mandu 권장 프리셋 (FSD + Clean 조합)
26
- *
27
- * 풀스택 프로젝트에 최적화
28
- */
29
- export const manduPreset: PresetDefinition = {
30
- name: "mandu",
31
- description: "Mandu 권장 아키텍처 - client/server 분리 + strict shared",
32
-
33
- hierarchy: [
34
- // Client (FSD)
35
- "client/app",
36
- "client/pages",
37
- "client/widgets",
38
- "client/features",
39
- "client/entities",
40
- "client/shared",
41
- // Shared (strict)
42
- "shared/contracts",
43
- "shared/types",
44
- "shared/utils/client",
45
- "shared/utils/server",
46
- "shared/schema",
47
- "shared/env",
48
- "shared/unsafe",
49
- // Server (Clean)
50
- "server/api",
51
- "server/application",
52
- "server/domain",
53
- "server/infra",
54
- "server/core",
55
- ],
56
-
57
- layers: [
58
- // Client layers
59
- {
60
- name: "client/app",
61
- pattern: "src/client/app/**",
62
- canImport: [
63
- "client/pages",
64
- "client/widgets",
65
- "client/features",
66
- "client/entities",
67
- "client/shared",
68
- "shared/contracts",
69
- "shared/types",
70
- "shared/utils/client",
71
- ],
72
- description: "클라이언트 앱 진입점",
73
- },
74
- {
75
- name: "client/pages",
76
- pattern: "src/client/pages/**",
77
- canImport: [
78
- "client/widgets",
79
- "client/features",
80
- "client/entities",
81
- "client/shared",
82
- "shared/contracts",
83
- "shared/types",
84
- "shared/utils/client",
85
- ],
86
- description: "클라이언트 페이지",
87
- },
88
- {
89
- name: "client/widgets",
90
- pattern: "src/client/widgets/**",
91
- canImport: [
92
- "client/features",
93
- "client/entities",
94
- "client/shared",
95
- "shared/contracts",
96
- "shared/types",
97
- "shared/utils/client",
98
- ],
99
- description: "클라이언트 위젯",
100
- },
101
- {
102
- name: "client/features",
103
- pattern: "src/client/features/**",
104
- canImport: [
105
- "client/entities",
106
- "client/shared",
107
- "shared/contracts",
108
- "shared/types",
109
- "shared/utils/client",
110
- ],
111
- description: "클라이언트 기능",
112
- },
113
- {
114
- name: "client/entities",
115
- pattern: "src/client/entities/**",
116
- canImport: [
117
- "client/shared",
118
- "shared/contracts",
119
- "shared/types",
120
- "shared/utils/client",
121
- ],
122
- description: "클라이언트 엔티티",
123
- },
124
- {
125
- name: "client/shared",
126
- pattern: "src/client/shared/**",
127
- canImport: [
128
- "shared/contracts",
129
- "shared/types",
130
- "shared/utils/client",
131
- ],
132
- description: "클라이언트 전용 공유",
133
- },
134
- // Shared layers
135
- {
136
- name: "shared/contracts",
137
- pattern: "src/shared/contracts/**",
138
- canImport: ["shared/types", "shared/utils/client"],
139
- description: "공용 계약 (클라이언트 safe)",
140
- },
141
- {
142
- name: "shared/schema",
143
- pattern: "src/shared/schema/**",
144
- canImport: ["shared/types", "shared/utils/server"],
145
- description: "서버 전용 스키마 (JSON/OpenAPI)",
146
- },
147
- {
148
- name: "shared/types",
149
- pattern: "src/shared/types/**",
150
- canImport: [],
151
- description: "공용 타입",
152
- },
153
- {
154
- name: "shared/utils/client",
155
- pattern: "src/shared/utils/client/**",
156
- canImport: ["shared/types"],
157
- description: "클라이언트 safe 유틸",
158
- },
159
- {
160
- name: "shared/utils/server",
161
- pattern: "src/shared/utils/server/**",
162
- canImport: ["shared/types", "shared/utils/client"],
163
- description: "서버 전용 유틸",
164
- },
165
- {
166
- name: "shared/env",
167
- pattern: "src/shared/env/**",
168
- canImport: ["shared/types", "shared/utils/client", "shared/utils/server"],
169
- description: "서버 전용 환경/설정",
170
- },
171
- {
172
- name: "shared/unsafe",
173
- pattern: "src/shared/**",
174
- canImport: [],
175
- description: "금지된 shared 경로",
176
- },
177
- // Server layers
178
- {
179
- name: "server/api",
180
- pattern: "src/server/api/**",
181
- canImport: [
182
- "server/application",
183
- "server/domain",
184
- "server/infra",
185
- "server/core",
186
- "shared/contracts",
187
- "shared/schema",
188
- "shared/types",
189
- "shared/utils/client",
190
- "shared/utils/server",
191
- "shared/env",
192
- ],
193
- description: "서버 API 라우트, 컨트롤러",
194
- },
195
- {
196
- name: "server/application",
197
- pattern: "src/server/application/**",
198
- canImport: [
199
- "server/domain",
200
- "server/core",
201
- "shared/contracts",
202
- "shared/schema",
203
- "shared/types",
204
- "shared/utils/client",
205
- "shared/utils/server",
206
- "shared/env",
207
- ],
208
- description: "서버 유스케이스, 서비스",
209
- },
210
- {
211
- name: "server/domain",
212
- pattern: "src/server/domain/**",
213
- canImport: [
214
- "shared/contracts",
215
- "shared/schema",
216
- "shared/types",
217
- "shared/utils/client",
218
- "shared/utils/server",
219
- "shared/env",
220
- ],
221
- description: "서버 도메인 모델",
222
- },
223
- {
224
- name: "server/infra",
225
- pattern: "src/server/infra/**",
226
- canImport: [
227
- "server/application",
228
- "server/domain",
229
- "server/core",
230
- "shared/contracts",
231
- "shared/schema",
232
- "shared/types",
233
- "shared/utils/client",
234
- "shared/utils/server",
235
- "shared/env",
236
- ],
237
- description: "서버 인프라 구현",
238
- },
239
- {
240
- name: "server/core",
241
- pattern: "src/server/core/**",
242
- canImport: [
243
- "shared/contracts",
244
- "shared/schema",
245
- "shared/types",
246
- "shared/utils/client",
247
- "shared/utils/server",
248
- "shared/env",
249
- ],
250
- description: "서버 핵심 공통",
251
- },
252
- ],
253
-
254
- defaultSeverity: {
255
- layerViolation: "error",
256
- circularDependency: "warn",
257
- crossSliceDependency: "warn",
258
- deepNesting: "info",
259
- fileType: "error",
260
- },
261
- };
262
-
263
- /**
264
- * 모든 프리셋 맵
265
- */
266
- export const presets: Record<GuardPreset, PresetDefinition> = {
267
- fsd: fsdPreset,
268
- clean: cleanPreset,
269
- hexagonal: hexagonalPreset,
270
- atomic: atomicPreset,
271
- cqrs: cqrsPreset,
272
- mandu: manduPreset,
273
- };
274
-
275
- /**
276
- * 프리셋 가져오기
277
- */
278
- export function getPreset(name: GuardPreset): PresetDefinition {
279
- const preset = presets[name];
280
- if (!preset) {
281
- throw new Error(`Unknown guard preset: ${name}`);
282
- }
283
- return preset;
284
- }
285
-
286
- /**
287
- * 프리셋 목록 가져오기
288
- */
289
- export function listPresets(): Array<{ name: GuardPreset; description: string }> {
290
- return Object.values(presets).map((p) => ({
291
- name: p.name,
292
- description: p.description,
293
- }));
294
- }
1
+ /**
2
+ * Guard Presets
3
+ *
4
+ * 아키텍처 프리셋 모음
5
+ */
6
+
7
+ import type { GuardPreset, PresetDefinition } from "../types";
8
+ import { fsdPreset, FSD_HIERARCHY } from "./fsd";
9
+ import { cleanPreset, CLEAN_HIERARCHY } from "./clean";
10
+ import { hexagonalPreset, HEXAGONAL_HIERARCHY } from "./hexagonal";
11
+ import { atomicPreset, ATOMIC_HIERARCHY } from "./atomic";
12
+ import { cqrsPreset, CQRS_HIERARCHY } from "./cqrs";
13
+
14
+ // Re-export types
15
+ export type { GuardPreset, PresetDefinition } from "../types";
16
+
17
+ // Re-export
18
+ export { fsdPreset, FSD_HIERARCHY } from "./fsd";
19
+ export { cleanPreset, CLEAN_HIERARCHY } from "./clean";
20
+ export { hexagonalPreset, HEXAGONAL_HIERARCHY } from "./hexagonal";
21
+ export { atomicPreset, ATOMIC_HIERARCHY } from "./atomic";
22
+ export { cqrsPreset, CQRS_HIERARCHY } from "./cqrs";
23
+
24
+ /**
25
+ * Mandu 권장 프리셋 (FSD + Clean 조합)
26
+ *
27
+ * 풀스택 프로젝트에 최적화
28
+ */
29
+ export const manduPreset: PresetDefinition = {
30
+ name: "mandu",
31
+ description: "Mandu 권장 아키텍처 - client/server 분리 + strict shared",
32
+
33
+ hierarchy: [
34
+ // Client (FSD)
35
+ "client/app",
36
+ "client/pages",
37
+ "client/widgets",
38
+ "client/features",
39
+ "client/entities",
40
+ "client/shared",
41
+ // Shared (strict)
42
+ "shared/contracts",
43
+ "shared/types",
44
+ "shared/utils/client",
45
+ "shared/utils/server",
46
+ "shared/schema",
47
+ "shared/env",
48
+ "shared/unsafe",
49
+ // Server (Clean)
50
+ "server/api",
51
+ "server/application",
52
+ "server/domain",
53
+ "server/infra",
54
+ "server/core",
55
+ ],
56
+
57
+ layers: [
58
+ // Client layers
59
+ {
60
+ name: "client/app",
61
+ pattern: "src/client/app/**",
62
+ canImport: [
63
+ "client/pages",
64
+ "client/widgets",
65
+ "client/features",
66
+ "client/entities",
67
+ "client/shared",
68
+ "shared/contracts",
69
+ "shared/types",
70
+ "shared/utils/client",
71
+ ],
72
+ description: "클라이언트 앱 진입점",
73
+ },
74
+ {
75
+ name: "client/pages",
76
+ pattern: "src/client/pages/**",
77
+ canImport: [
78
+ "client/widgets",
79
+ "client/features",
80
+ "client/entities",
81
+ "client/shared",
82
+ "shared/contracts",
83
+ "shared/types",
84
+ "shared/utils/client",
85
+ ],
86
+ description: "클라이언트 페이지",
87
+ },
88
+ {
89
+ name: "client/widgets",
90
+ pattern: "src/client/widgets/**",
91
+ canImport: [
92
+ "client/features",
93
+ "client/entities",
94
+ "client/shared",
95
+ "shared/contracts",
96
+ "shared/types",
97
+ "shared/utils/client",
98
+ ],
99
+ description: "클라이언트 위젯",
100
+ },
101
+ {
102
+ name: "client/features",
103
+ pattern: "src/client/features/**",
104
+ canImport: [
105
+ "client/entities",
106
+ "client/shared",
107
+ "shared/contracts",
108
+ "shared/types",
109
+ "shared/utils/client",
110
+ ],
111
+ description: "클라이언트 기능",
112
+ },
113
+ {
114
+ name: "client/entities",
115
+ pattern: "src/client/entities/**",
116
+ canImport: [
117
+ "client/shared",
118
+ "shared/contracts",
119
+ "shared/types",
120
+ "shared/utils/client",
121
+ ],
122
+ description: "클라이언트 엔티티",
123
+ },
124
+ {
125
+ name: "client/shared",
126
+ pattern: "src/client/shared/**",
127
+ canImport: [
128
+ "shared/contracts",
129
+ "shared/types",
130
+ "shared/utils/client",
131
+ ],
132
+ description: "클라이언트 전용 공유",
133
+ },
134
+ // Shared layers
135
+ // Patterns use brace expansion to match both directory contents (e.g. src/shared/types/**)
136
+ // and direct files (e.g. src/shared/types.ts, src/shared/types.tsx)
137
+ {
138
+ name: "shared/contracts",
139
+ pattern: "src/shared/contracts{/**,.ts,.tsx}",
140
+ canImport: ["shared/types", "shared/utils/client"],
141
+ description: "공용 계약 (클라이언트 safe)",
142
+ },
143
+ {
144
+ name: "shared/schema",
145
+ pattern: "src/shared/schema{/**,.ts,.tsx}",
146
+ canImport: ["shared/types", "shared/utils/server"],
147
+ description: "서버 전용 스키마 (JSON/OpenAPI)",
148
+ },
149
+ {
150
+ name: "shared/types",
151
+ pattern: "src/shared/types{/**,.ts,.tsx}",
152
+ canImport: [],
153
+ description: "공용 타입",
154
+ },
155
+ {
156
+ name: "shared/utils/client",
157
+ pattern: "src/shared/utils/client{/**,.ts,.tsx}",
158
+ canImport: ["shared/types"],
159
+ description: "클라이언트 safe 유틸",
160
+ },
161
+ {
162
+ name: "shared/utils/server",
163
+ pattern: "src/shared/utils/server{/**,.ts,.tsx}",
164
+ canImport: ["shared/types", "shared/utils/client"],
165
+ description: "서버 전용 유틸",
166
+ },
167
+ {
168
+ name: "shared/env",
169
+ pattern: "src/shared/env{/**,.ts,.tsx}",
170
+ canImport: ["shared/types", "shared/utils/client", "shared/utils/server"],
171
+ description: "서버 전용 환경/설정",
172
+ },
173
+ {
174
+ name: "shared/unsafe",
175
+ pattern: "src/shared/**",
176
+ canImport: [],
177
+ description: "금지된 shared 경로",
178
+ },
179
+ // Server layers
180
+ {
181
+ name: "server/api",
182
+ pattern: "src/server/api/**",
183
+ canImport: [
184
+ "server/application",
185
+ "server/domain",
186
+ "server/infra",
187
+ "server/core",
188
+ "shared/contracts",
189
+ "shared/schema",
190
+ "shared/types",
191
+ "shared/utils/client",
192
+ "shared/utils/server",
193
+ "shared/env",
194
+ ],
195
+ description: "서버 API 라우트, 컨트롤러",
196
+ },
197
+ {
198
+ name: "server/application",
199
+ pattern: "src/server/application/**",
200
+ canImport: [
201
+ "server/domain",
202
+ "server/core",
203
+ "shared/contracts",
204
+ "shared/schema",
205
+ "shared/types",
206
+ "shared/utils/client",
207
+ "shared/utils/server",
208
+ "shared/env",
209
+ ],
210
+ description: "서버 유스케이스, 서비스",
211
+ },
212
+ {
213
+ name: "server/domain",
214
+ pattern: "src/server/domain/**",
215
+ canImport: [
216
+ "shared/contracts",
217
+ "shared/schema",
218
+ "shared/types",
219
+ "shared/utils/client",
220
+ "shared/utils/server",
221
+ "shared/env",
222
+ ],
223
+ description: "서버 도메인 모델",
224
+ },
225
+ {
226
+ name: "server/infra",
227
+ pattern: "src/server/infra/**",
228
+ canImport: [
229
+ "server/application",
230
+ "server/domain",
231
+ "server/core",
232
+ "shared/contracts",
233
+ "shared/schema",
234
+ "shared/types",
235
+ "shared/utils/client",
236
+ "shared/utils/server",
237
+ "shared/env",
238
+ ],
239
+ description: "서버 인프라 구현",
240
+ },
241
+ {
242
+ name: "server/core",
243
+ pattern: "src/server/core/**",
244
+ canImport: [
245
+ "shared/contracts",
246
+ "shared/schema",
247
+ "shared/types",
248
+ "shared/utils/client",
249
+ "shared/utils/server",
250
+ "shared/env",
251
+ ],
252
+ description: "서버 핵심 공통",
253
+ },
254
+ ],
255
+
256
+ defaultSeverity: {
257
+ layerViolation: "error",
258
+ circularDependency: "warn",
259
+ crossSliceDependency: "warn",
260
+ deepNesting: "info",
261
+ fileType: "error",
262
+ },
263
+ };
264
+
265
+ /**
266
+ * 모든 프리셋
267
+ */
268
+ export const presets: Record<GuardPreset, PresetDefinition> = {
269
+ fsd: fsdPreset,
270
+ clean: cleanPreset,
271
+ hexagonal: hexagonalPreset,
272
+ atomic: atomicPreset,
273
+ cqrs: cqrsPreset,
274
+ mandu: manduPreset,
275
+ };
276
+
277
+ /**
278
+ * 프리셋 가져오기
279
+ */
280
+ export function getPreset(name: GuardPreset): PresetDefinition {
281
+ const preset = presets[name];
282
+ if (!preset) {
283
+ throw new Error(`Unknown guard preset: ${name}`);
284
+ }
285
+ return preset;
286
+ }
287
+
288
+ /**
289
+ * 프리셋 목록 가져오기
290
+ */
291
+ export function listPresets(): Array<{ name: GuardPreset; description: string }> {
292
+ return Object.values(presets).map((p) => ({
293
+ name: p.name,
294
+ description: p.description,
295
+ }));
296
+ }
@@ -15,12 +15,6 @@ export interface GuardRule {
15
15
  }
16
16
 
17
17
  export const GUARD_RULES: Record<string, GuardRule> = {
18
- SPEC_HASH_MISMATCH: {
19
- id: "SPEC_HASH_MISMATCH",
20
- name: "Spec Hash Mismatch",
21
- description: "spec.lock.json의 해시와 현재 spec이 일치하지 않습니다",
22
- severity: "error",
23
- },
24
18
  GENERATED_MANUAL_EDIT: {
25
19
  id: "GENERATED_MANUAL_EDIT",
26
20
  name: "Generated File Manual Edit",
@@ -64,18 +58,18 @@ export const GUARD_RULES: Record<string, GuardRule> = {
64
58
  description: "Slot 핸들러에 ctx.ok(), ctx.json() 등의 응답 패턴이 없습니다",
65
59
  severity: "error",
66
60
  },
67
- SLOT_MISSING_FILLING_PATTERN: {
68
- id: "SLOT_MISSING_FILLING_PATTERN",
69
- name: "Slot Missing Filling Pattern",
70
- description: "Slot 파일에 Mandu.filling() 패턴이 없습니다",
71
- severity: "error",
72
- },
73
- SLOT_ZOD_DIRECT_IMPORT: {
74
- id: "SLOT_ZOD_DIRECT_IMPORT",
75
- name: "Zod Direct Import in Slot",
76
- description: "Slot 파일에서 zod를 직접 import 했습니다",
77
- severity: "error",
78
- },
61
+ SLOT_MISSING_FILLING_PATTERN: {
62
+ id: "SLOT_MISSING_FILLING_PATTERN",
63
+ name: "Slot Missing Filling Pattern",
64
+ description: "Slot 파일에 Mandu.filling() 패턴이 없습니다",
65
+ severity: "error",
66
+ },
67
+ SLOT_ZOD_DIRECT_IMPORT: {
68
+ id: "SLOT_ZOD_DIRECT_IMPORT",
69
+ name: "Zod Direct Import in Slot",
70
+ description: "Slot 파일에서 zod를 직접 import 했습니다",
71
+ severity: "error",
72
+ },
79
73
  // Contract-related rules
80
74
  CONTRACT_MISSING: {
81
75
  id: "CONTRACT_MISSING",
@@ -105,7 +99,9 @@ export const GUARD_RULES: Record<string, GuardRule> = {
105
99
  ISLAND_FIRST_INTEGRITY: {
106
100
  id: "ISLAND_FIRST_INTEGRITY",
107
101
  name: "Island-First Integrity",
108
- description: "clientModule이 있는 page route의 componentModule이 island을 import하지 않습니다",
102
+ description:
103
+ "A page route has a clientModule defined but the island file does not exist. " +
104
+ "Create a .island.tsx file in the same directory; do NOT import island() into page.tsx.",
109
105
  severity: "error",
110
106
  },
111
107
  CLIENT_MODULE_NOT_FOUND: {