@eliceio/cdk-cli 0.1.0-alpha.6 → 0.1.0-alpha.8

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 (87) hide show
  1. package/README.md +110 -104
  2. package/es/cli.js +7 -22
  3. package/es/commands/build/index.d.ts +3 -21
  4. package/es/commands/build/index.js +17 -140
  5. package/es/commands/create/scaffold.d.ts +2 -0
  6. package/es/commands/create/scaffold.js +15 -1
  7. package/es/commands/doctor/index.d.ts +4 -3
  8. package/es/commands/doctor/index.js +14 -14
  9. package/es/commands/setup/index.d.ts +4 -7
  10. package/es/commands/setup/index.js +41 -70
  11. package/es/commands/uninstall/index.d.ts +9 -8
  12. package/es/commands/uninstall/index.js +41 -47
  13. package/es/commands/update/index.d.ts +4 -2
  14. package/es/commands/update/index.js +27 -18
  15. package/es/commands/validate/index.js +3 -1
  16. package/es/core/collect.d.ts +1 -1
  17. package/es/core/collect.js +3 -1
  18. package/es/core/config.d.ts +2 -2
  19. package/es/core/config.js +3 -3
  20. package/es/core/manifest.d.ts +3 -3
  21. package/es/core/manifest.js +4 -8
  22. package/es/{commands/mcp/index.d.ts → core/mcp.d.ts} +11 -18
  23. package/es/{commands/mcp/index.js → core/mcp.js} +29 -51
  24. package/es/core/prepare.d.ts +15 -10
  25. package/es/core/prepare.js +35 -35
  26. package/es/core/project-check.d.ts +6 -5
  27. package/es/core/project-check.js +9 -9
  28. package/es/core/sandbox.d.ts +6 -5
  29. package/es/core/sandbox.js +30 -8
  30. package/es/core/sdk.d.ts +7 -18
  31. package/es/core/sdk.js +8 -38
  32. package/es/{commands/skill/index.d.ts → core/skills.d.ts} +1 -17
  33. package/es/{commands/skill/index.js → core/skills.js} +6 -22
  34. package/es/dev/grading.d.ts +1 -1
  35. package/es/dev/grading.js +1 -1
  36. package/es/dev/host-page.js +2 -2
  37. package/es/dev/server.d.ts +6 -4
  38. package/es/dev/server.js +47 -77
  39. package/es/engines/vite/index.d.ts +2 -2
  40. package/es/engines/vite/index.js +2 -4
  41. package/es/engines/vite/plugin.d.ts +58 -0
  42. package/es/engines/vite/plugin.js +286 -0
  43. package/es/engines/vite/run.d.ts +15 -0
  44. package/es/engines/vite/run.js +92 -0
  45. package/es/rules/check.js +10 -12
  46. package/es/rules/csp.d.ts +1 -1
  47. package/es/rules/csp.js +1 -1
  48. package/es/rules/types.d.ts +8 -3
  49. package/es/rules.json.js +1 -1
  50. package/es/test-packages.d.ts +3 -1
  51. package/package.json +8 -3
  52. package/rules.json +9 -3
  53. package/skills/_shared/always.md +1 -1
  54. package/skills/elice-content-create/SKILL.md +2 -1
  55. package/skills/elice-content-guide/topics/01-check-the-environment.md +2 -2
  56. package/skills/elice-content-guide/topics/02-design-the-material.md +2 -0
  57. package/skills/elice-content-guide/topics/03-create-the-project.md +3 -3
  58. package/skills/elice-content-guide/topics/04-rules.md +1 -1
  59. package/skills/elice-content-guide/topics/05-screen-code.md +44 -13
  60. package/skills/elice-content-guide/topics/07-move-existing-html.md +2 -2
  61. package/skills/elice-content-guide/topics/08-fix-check-errors.md +21 -21
  62. package/skills/elice-content-guide/topics/10-build.md +1 -1
  63. package/skills/elice-content-guide/topics/12-upload-with-the-material-mcp.md +2 -2
  64. package/skills/elice-content-publish/SKILL.md +1 -1
  65. package/templates/_shared/lib/cdk-mock.js +2 -2
  66. package/templates/_shared/lib/elice-content-editor.d.ts +80 -0
  67. package/templates/_shared/lib/elice-content-editor.js +1062 -0
  68. package/templates/_shared/lib/elice-content.css +332 -0
  69. package/templates/_shared/lib/elice-content.js +18 -15
  70. package/templates/blank/README.md +29 -5
  71. package/templates/blank/commentary.txt +5 -0
  72. package/templates/blank/screens/edit.js +38 -17
  73. package/templates/blank/screens/instructor.js +20 -8
  74. package/templates/blank/screens/learn.js +151 -13
  75. package/templates/blank/styles.css +171 -0
  76. package/templates/blank/template.json +2 -2
  77. package/templates/quiz/README.md +2 -3
  78. package/templates/quiz/core/model.js +1 -1
  79. package/templates/quiz/screens/edit.js +14 -2
  80. package/templates/quiz/styles.css +11 -0
  81. package/templates/quiz/template.json +1 -1
  82. package/templates/quiz/ui/texts.js +1 -1
  83. package/es/core/minify.d.ts +0 -18
  84. package/es/core/minify.js +0 -93
  85. package/es/engines/static/index.d.ts +0 -3
  86. package/es/engines/static/index.js +0 -11
  87. package/es/engines/types.d.ts +0 -12
@@ -4,20 +4,16 @@ import { homedir } from 'node:os';
4
4
  import { delimiter, join, dirname } from 'node:path';
5
5
 
6
6
  /*
7
- * Elice 학습자료 서버 MCP(elice-material)를 AI 도구에 등록한다 (명령은 ecdk setup --only mcp · ecdk setup).
7
+ * Elice 학습자료 서버 MCP(elice-material)를 AI 도구에 등록 · 확인한다 (ecdk setup · uninstall · doctor가 쓴다).
8
8
  * 등록 전에 서버에 MCP가 있는지 확인하고, 로그인은 등록 뒤 각 도구에서 한다.
9
9
  */
10
10
  const MCP_NAME = 'elice-material';
11
11
  /**
12
- * 서버 환경 → MCP 주소. 표는 여기 하나만 둔다.
13
- * prod는 material API 주소(api-material.elice.io)에 /mcp를 붙인 **가정**이다: 2026-11-10 운영에는 아직 MCP가 없고
14
- * (GET 405), 백엔드가 주소를 확정해 주기로 함 (백엔드 요청 B1). 그래서 등록 전에 probe로 확인한다.
12
+ * 운영 서버 MCP 주소. 그 밖의 서버는 --url로 준다 (사내 서버 주소는 패키지에 두지 않음).
13
+ * material API 주소(api-material.elice.io)에 /mcp를 붙인 **가정**이다: 2026-11-10 운영에는 아직 MCP가 없고
14
+ * (GET 405), 백엔드가 주소를 확정해 주기로 함. 그래서 등록 전에 probe로 확인한다.
15
15
  */
16
- const MCP_ENVS = {
17
- prod: 'https://api-material.elice.io/mcp',
18
- qa5: 'https://dev-v5-material-api.dev.elicer.io/mcp'
19
- };
20
- const DEFAULT_ENV = 'prod';
16
+ const MCP_URL = 'https://api-material.elice.io/mcp';
21
17
  const PROBE_TIMEOUT_MS = 5000;
22
18
  /** MCP initialize를 POST해 본다. 로그인 전이면 401과 www-authenticate(resource_metadata)가 와야 한다 */
23
19
  async function probeMcp(url) {
@@ -85,8 +81,7 @@ function defaultMcpEnv() {
85
81
  };
86
82
  },
87
83
  exists: existsSync,
88
- probe: probeMcp,
89
- envVar: process.env.ECDK_ENV
84
+ probe: probeMcp
90
85
  };
91
86
  }
92
87
  const helpyConfigPath = env => join(env.home, '.config', 'helpycode', 'helpycode.jsonc');
@@ -96,8 +91,8 @@ function detectTargets(env) {
96
91
  if (env.exists(join(env.home, '.config', 'helpycode')) || env.which('helpycode') || env.platform === 'darwin' && env.exists('/Applications/HelpyCode.app')) found.push('helpycode');
97
92
  return found;
98
93
  }
99
- /** 주소로 환경 이름 (표에 없으면 custom) */
100
- const envOfUrl = url => Object.entries(MCP_ENVS).find(([, u]) => u === url)?.[0] ?? 'custom';
94
+ /** 주소로 환경 이름: 운영 주소면 prod, 아니면 custom (--url로 준 주소) */
95
+ const envOfUrl = url => url === MCP_URL ? 'prod' : 'custom';
101
96
  const CLAUDE_TIMEOUT_MS = 5000;
102
97
  /**
103
98
  * Claude Code 등록 상태. `claude mcp get`은 서버 연결 상태까지 확인해 느릴 수 있으므로
@@ -129,11 +124,6 @@ function claudeRegistration(env) {
129
124
  url
130
125
  };
131
126
  }
132
- /** Claude Code 사용자 범위에 등록된 주소 (없거나 확인 못 하면 null) */
133
- function claudeRegisteredUrl(env) {
134
- const reg = claudeRegistration(env);
135
- return reg.state === 'user' ? reg.url : null;
136
- }
137
127
  /** 주석 · 끝 쉼표가 있으면 다시 쓰지 않는다 (지우면 사람이 적은 설명이 사라짐) */
138
128
  function readHelpyConfig(path) {
139
129
  if (!existsSync(path)) return {
@@ -174,7 +164,7 @@ function helpyRegisteredUrl(env) {
174
164
  const mcp = config.data.mcp;
175
165
  return mcp?.[MCP_NAME]?.url ?? null;
176
166
  }
177
- function setupClaude(env, url, dryRun, force) {
167
+ function setupClaude(env, url, force) {
178
168
  const reg = claudeRegistration(env);
179
169
  if (reg.state === 'unknown') return {
180
170
  target: 'claude',
@@ -194,11 +184,6 @@ function setupClaude(env, url, dryRun, force) {
194
184
  message: `다른 주소로 등록돼 있습니다 (${current}). 바꾸려면 --force`
195
185
  };
196
186
  const add = ['mcp', 'add', '--transport', 'http', '--scope', 'user', MCP_NAME, url];
197
- if (dryRun) return {
198
- target: 'claude',
199
- action: current ? 'would-replace' : 'would-add',
200
- message: `${current ? `claude mcp remove ${MCP_NAME} --scope user 뒤 ` : ''}claude ${add.join(' ')}${localNote}`
201
- };
202
187
  if (current) {
203
188
  const rm = env.exec('claude', ['mcp', 'remove', MCP_NAME, '--scope', 'user'], 30000);
204
189
  if (rm.code !== 0 || rm.timedOut) return {
@@ -219,7 +204,7 @@ function setupClaude(env, url, dryRun, force) {
219
204
  message: `Claude Code 사용자 설정에 ${current ? '바꿈' : '등록'} (${url})${localNote}`
220
205
  };
221
206
  }
222
- function setupHelpy(env, url, dryRun, force) {
207
+ function setupHelpy(env, url, force) {
223
208
  const path = helpyConfigPath(env);
224
209
  const config = readHelpyConfig(path);
225
210
  const block = JSON.stringify({
@@ -260,11 +245,6 @@ function setupHelpy(env, url, dryRun, force) {
260
245
  action: 'conflict',
261
246
  message: `다른 주소로 등록돼 있습니다 (${current}). 바꾸려면 --force`
262
247
  };
263
- if (dryRun) return {
264
- target: 'helpycode',
265
- action: current ? 'would-replace' : 'would-add',
266
- message: `${path}의 mcp.${MCP_NAME}를 ${url}로${config.kind === 'json' ? env.exists(`${path}.bak`) ? ' (.bak은 이미 있어 그대로 둠)' : ' (원본은 .bak)' : ' (새 파일)'}`
267
- };
268
248
  mcp[MCP_NAME] = helpyEntry(url);
269
249
  data.mcp = mcp;
270
250
  mkdirSync(dirname(path), {
@@ -294,9 +274,9 @@ async function setup(opts) {
294
274
  url
295
275
  } = opts;
296
276
  const targets = opts.target === 'all' ? detectTargets(opts.env) : [opts.target];
297
- const login = [...targets.flatMap(t => LOGIN[t]), ...(opts.envName === 'qa5' ? ['로그인 창(accounts.qa-web-5)에서 dev5 계정으로 로그인'] : [])];
298
- const probe = opts.dryRun ? 'skipped' : await opts.env.probe(url);
299
- if (probe !== 'skipped' && !probe.ok && !opts.force) return {
277
+ const login = targets.flatMap(t => LOGIN[t]);
278
+ const probe = await opts.env.probe(url);
279
+ if (!probe.ok && !opts.force) return {
300
280
  env: opts.envName,
301
281
  probe,
302
282
  url,
@@ -308,7 +288,7 @@ async function setup(opts) {
308
288
  })),
309
289
  login
310
290
  };
311
- const steps = targets.map(t => t === 'claude' ? setupClaude(opts.env, url, opts.dryRun, opts.force) : setupHelpy(opts.env, url, opts.dryRun, opts.force));
291
+ const steps = targets.map(t => t === 'claude' ? setupClaude(opts.env, url, opts.force) : setupHelpy(opts.env, url, opts.force));
312
292
  return {
313
293
  env: opts.envName,
314
294
  probe,
@@ -319,30 +299,28 @@ async function setup(opts) {
319
299
  };
320
300
  }
321
301
  const NEEDS_PERSON = ['conflict', 'manual', 'unreachable', 'failed'];
322
- /** 주소: --url > --env > ECDK_ENV > prod */
323
- function resolveUrl(args, env) {
324
- if (args.url && !/^https:\/\/\S+$/.test(args.url)) return {
325
- ok: false,
326
- error: `--url은 https 주소여야 합니다: ${args.url}`
302
+ /** 주소: --url, 없으면 운영 */
303
+ function resolveUrl(args) {
304
+ if (args.url === undefined) return {
305
+ ok: true,
306
+ envName: envOfUrl(MCP_URL),
307
+ source: '기본값',
308
+ url: MCP_URL
327
309
  };
328
- const envName = args.url ? envOfUrl(args.url) : args.envName ?? env.envVar ?? DEFAULT_ENV;
329
- const source = args.url ? '--url' : args.envName ? '--env' : env.envVar ? 'ECDK_ENV' : '기본값';
330
- const url = args.url ?? MCP_ENVS[envName];
331
- if (!url) return {
310
+ if (!/^https:\/\/\S+$/.test(args.url)) return {
332
311
  ok: false,
333
- error: `알 수 없는 환경: ${envName} (가능: ${Object.keys(MCP_ENVS).join(', ')}, 그 밖은 --url)`
312
+ error: `--url은 https 주소여야 합니다: ${args.url}`
334
313
  };
335
314
  return {
336
315
  ok: true,
337
- envName,
338
- source,
339
- url
316
+ envName: envOfUrl(args.url),
317
+ source: '--url',
318
+ url: args.url
340
319
  };
341
320
  }
342
321
  /** 사람용 출력의 MCP 부분 (환경 · 서버 확인 · 도구별 결과) */
343
- function formatSetupLines(result, source, dryRun) {
344
- const probeLine = result.probe === 'skipped' ? '서버 확인: 건너뜀 (--dry-run)' : `서버 확인: ${result.probe.ok ? 'MCP 있음' : 'MCP 없음'} (${result.probe.detail})`;
345
- return [`MCP ${MCP_NAME} · 환경 ${result.env} (${source}) · ${result.url}${dryRun ? ' · 미리보기(--dry-run)' : ''}`, probeLine, ...(result.env === 'prod' ? [] : [`※ 운영이 아닌 환경(${result.env})입니다. 운영 자료를 올리지 마세요.`]), ...result.steps.flatMap(s => [` ${s.target}: ${s.message}`, ...(s.paste ? s.paste.split('\n').map(l => ` ${l}`) : [])])];
322
+ function formatSetupLines(result, source) {
323
+ return [`MCP ${MCP_NAME} · 환경 ${result.env} (${source}) · ${result.url}`, `서버 확인: ${result.probe.ok ? 'MCP 있음' : 'MCP 없음'} (${result.probe.detail})`, ...(result.env === 'prod' ? [] : [`※ 운영이 아닌 서버(--url)입니다. 운영 자료를 올리지 마세요.`]), ...result.steps.flatMap(s => [` ${s.target}: ${s.message}`, ...(s.paste ? s.paste.split('\n').map(l => ` ${l}`) : [])])];
346
324
  }
347
325
 
348
- export { DEFAULT_ENV, MCP_ENVS, MCP_NAME, NEEDS_PERSON, claudeRegisteredUrl, claudeRegistration, defaultMcpEnv, detectTargets, envOfUrl, formatSetupLines, helpyConfigPath, helpyRegisteredUrl, probeMcp, readHelpyConfig, resolveUrl, setup };
326
+ export { MCP_NAME, MCP_URL, NEEDS_PERSON, claudeRegistration, defaultMcpEnv, detectTargets, envOfUrl, formatSetupLines, helpyConfigPath, helpyRegisteredUrl, probeMcp, readHelpyConfig, resolveUrl, setup };
@@ -1,28 +1,33 @@
1
1
  import { type Excluded, type SourceFile } from './collect.js';
2
2
  import { type ContentConfig } from './config.js';
3
+ /** 빌드 엔진 (metadata.json build.engine). ecdk build · dev는 Vite 위에서 돈다 (engines/vite) */
4
+ export declare const ENGINE = "vite";
5
+ /** Vite 기본 public 폴더 (원본 폴더 기준). 안의 파일은 묶지 않고 그대로 zip 최상위 경로에 들어간다 */
6
+ export declare const PUBLIC_DIR = "public/";
3
7
  export interface PreparedContent {
4
8
  srcDir: string;
5
9
  outDir: string;
6
10
  engine: string;
7
- /** zip에 들어갈 파일 전부 (metadata.json 포함) */
11
+ /** 원본 중 zip 대상 파일 전부 (metadata.json 포함, 번들 전, public/ 파일은 zip 경로로). 검사는 이 원본으로 한다 */
8
12
  files: SourceFile[];
13
+ /** public/ 폴더의 파일 (zip 경로, public/ 뺀 것). build가 원본 그대로 zip에 넣는다 */
14
+ publicFiles: Set<string>;
9
15
  excluded: Excluded[];
10
16
  sdk: PreparedSdk;
11
17
  }
12
- /** SDK(@eliceio/cdk)를 어디서 넣었는지 (ADR 0010 최종 결정) */
18
+ /** SDK(@eliceio/cdk) 의존성 상태 (ADR 0010). SDK는 build가 번들로 묶고 파일로 넣지 않는다 */
13
19
  export interface PreparedSdk {
14
20
  /** package.json에 @eliceio/cdk가 있는지 */
15
21
  declared: boolean;
16
22
  /** 적은 범위 */
17
23
  range?: string | undefined;
18
- /** zip에 넣은 설치 버전 */
24
+ /** 설치된 버전 (metadata.json build.sdk) */
19
25
  version?: string | undefined;
20
- /** 적었는데 node_modules에 없음 (requireSdk: false일 때만, 아니면 오류) */
26
+ /** 적었는데 node_modules에 없음 (build는 오류, dev · doctor는 알림) */
21
27
  missing: boolean;
22
- /** package.json에 없고 원본에 lib/cdk.js 복사본이 있는 옛 프로젝트 (sdk.lib-copy 경고) */
23
- legacyCopy: boolean;
24
28
  }
25
- /** build와 doctor가 같은 결과를 보도록: 수집 → 엔진 → metadata.json(화면 + 빌드 정보). 디스크에는 쓰지 않는다. */
26
- export declare function prepareContent(projectDir: string, config: ContentConfig, options?: {
27
- requireSdk?: boolean;
28
- }): Promise<PreparedContent>;
29
+ /**
30
+ * build · dev · doctor가 같은 결과를 보도록: 수집 → metadata.json(화면 + 빌드 정보). 디스크에는 쓰지 않는다.
31
+ * 번들은 하지 않는다 (Vite 플러그인 engines/vite가 이 결과로 입력 HTML · 그대로 넣을 파일 · 검사를 정한다)
32
+ */
33
+ export declare function prepareContent(projectDir: string, config: ContentConfig): Promise<PreparedContent>;
@@ -1,19 +1,25 @@
1
1
  import { resolve, relative, sep, isAbsolute } from 'node:path';
2
- import { staticEngine } from '../engines/static/index.js';
3
2
  import 'fflate';
4
3
  import { rules } from '../rules/spec.js';
5
4
  import { serializeManifest } from '../rules/manifest.js';
6
5
  import { collectSources } from './collect.js';
7
6
  import { CONFIG_FILE, PLATFORM_KEYS } from './config.js';
8
7
  import { createBuildInfo } from './manifest.js';
9
- import { readProjectSdk, SDK_ZIP_PATH, sdkZipFile, missingSdkMessage } from './sdk.js';
8
+ import { LEGACY_SDK_COPY, readProjectSdk } from './sdk.js';
10
9
 
10
+ /** 빌드 엔진 (metadata.json build.engine). ecdk build · dev는 Vite 위에서 돈다 (engines/vite) */
11
+ const ENGINE = 'vite';
12
+ /** Vite 기본 public 폴더 (원본 폴더 기준). 안의 파일은 묶지 않고 그대로 zip 최상위 경로에 들어간다 */
13
+ const PUBLIC_DIR = 'public/';
11
14
  const isInside = (parent, child) => {
12
15
  const rel = relative(parent, child);
13
16
  return rel !== '' && !rel.startsWith('..') && !isAbsolute(rel);
14
17
  };
15
- /** build와 doctor가 같은 결과를 보도록: 수집 → 엔진 → metadata.json(화면 + 빌드 정보). 디스크에는 쓰지 않는다. */
16
- async function prepareContent(projectDir, config, options = {}) {
18
+ /**
19
+ * build · dev · doctor가 같은 결과를 보도록: 수집 → metadata.json(화면 + 빌드 정보). 디스크에는 쓰지 않는다.
20
+ * 번들은 하지 않는다 (Vite 플러그인 engines/vite가 이 결과로 입력 HTML · 그대로 넣을 파일 · 검사를 정한다)
21
+ */
22
+ async function prepareContent(projectDir, config) {
17
23
  const srcDir = resolve(projectDir, config.root);
18
24
  const outDir = resolve(projectDir, config.outDir);
19
25
  // build는 <outDir>/content/를 지우고 다시 만든다: 프로젝트 밖이나 프로젝트 폴더 자체를 가리키면 다른 데이터를 지울 수 있다
@@ -28,42 +34,35 @@ async function prepareContent(projectDir, config, options = {}) {
28
34
  const {
29
35
  excluded
30
36
  } = collected;
31
- let sources = collected.files;
32
- // SDK: package.json에 @eliceio/cdk가 있으면 설치된 UMD 빌드를 zip lib/cdk.js로 넣는다 (원본에 옛 복사본이 있으면 대신함).
33
- // 없으면(옛 프로젝트) 원본 lib/cdk.js 복사본을 그대로 쓰고 sdk.lib-copy로 옮기는 법을 알린다.
34
- // dev는 설치 전에도 mock으로 열리게 requireSdk: false (실제 SDK 모드만 lib/cdk.js가 없어 실패)
37
+ // SDK 복사본(옛 lib/cdk.js)은 zip에 넣지 않는다: SDK는 package.json 의존성을 번들로 묶는다 (검사 sdk.lib-copy가 오류로 알림)
38
+ const kept = collected.files.filter(f => f.path !== LEGACY_SDK_COPY);
39
+ if (kept.length !== collected.files.length) excluded.push({
40
+ path: LEGACY_SDK_COPY,
41
+ reason: 'sdk'
42
+ });
43
+ // public/ 파일은 Vite처럼 zip 최상위 경로로 (실행 중 문자열 경로로 받는 파일 · 일반 <script src>)
44
+ const publicFiles = new Set();
45
+ const files = kept.map(f => {
46
+ if (!f.path.startsWith(PUBLIC_DIR)) return f;
47
+ const path = f.path.slice(PUBLIC_DIR.length);
48
+ publicFiles.add(path);
49
+ return {
50
+ ...f,
51
+ path
52
+ };
53
+ });
35
54
  const projectSdk = await readProjectSdk(projectDir);
36
55
  const sdk = {
37
56
  declared: projectSdk !== null,
38
57
  range: projectSdk?.range,
39
- missing: false,
40
- legacyCopy: projectSdk === null && sources.some(f => f.path === SDK_ZIP_PATH)
58
+ version: projectSdk?.installed?.version,
59
+ missing: projectSdk !== null && !projectSdk.installed
41
60
  };
42
- if (projectSdk) {
43
- const replaced = sources.some(f => f.path === SDK_ZIP_PATH);
44
- if (replaced) {
45
- excluded.push({
46
- path: SDK_ZIP_PATH,
47
- reason: 'sdk'
48
- });
49
- sources = sources.filter(f => f.path !== SDK_ZIP_PATH);
50
- }
51
- if (projectSdk.installed) {
52
- sources = [...sources, await sdkZipFile(projectSdk.installed)];
53
- sdk.version = projectSdk.installed.version;
54
- } else if (options.requireSdk === false) sdk.missing = true;else throw new Error(missingSdkMessage());
55
- }
56
- const engine = staticEngine;
57
- const files = await engine.build({
58
- srcDir,
59
- files: sources
60
- });
61
61
  // metadata.json (zip 최상위, ADR 0011): 원본에 작성자가 쓴 것을 그대로 두고 build만 채운다.
62
- // 원본에 없으면 옛 elice.config.json의 kind · screens로 만들고, 그것도 없으면 학생 화면만.
63
- // build.sdk는 zip lib/cdk.js 머리말에서 (설치된 SDK를 넣었으면 그 버전)
64
- const build = createBuildInfo(engine.name, {
62
+ // 원본에 없으면 옛 elice.config.json의 kind · screens로 만들고, 그것도 없으면 학생 화면만
63
+ const build = createBuildInfo(ENGINE, {
65
64
  template: config.template,
66
- files
65
+ sdk: sdk.version
67
66
  });
68
67
  // 학습 참고 내용 (만들 때만): 원본 최상위 .txt 파일을 zip에 그대로 두고, metadata.json commentary에 이름만 적는다
69
68
  const legacy = config.legacy ?? {};
@@ -106,11 +105,12 @@ async function prepareContent(projectDir, config, options = {}) {
106
105
  return {
107
106
  srcDir,
108
107
  outDir,
109
- engine: engine.name,
108
+ engine: ENGINE,
110
109
  files,
110
+ publicFiles,
111
111
  excluded,
112
112
  sdk
113
113
  };
114
114
  }
115
115
 
116
- export { prepareContent };
116
+ export { ENGINE, PUBLIC_DIR, prepareContent };
@@ -6,21 +6,22 @@ import type { CheckOptions } from '../rules/index.js';
6
6
  */
7
7
  export declare function findLegacyFiles(projectDir: string, config: ContentConfig): Promise<string[]>;
8
8
  /**
9
- * 옛 lib/cdk.js 복사본 (ADR 0010 최종 결정): package.json에 @eliceio/cdk가 없는데 원본에 lib/cdk.js가 있으면 그 경로
10
- * (프로젝트 기준). build는 복사본을 그대로 넣고 sdk.lib-copy로 옮기는 법을 알린다
9
+ * 옛 SDK 복사본 (ADR 0010): 원본에 lib/cdk.js가 있으면 그 경로 (프로젝트 기준). SDK는 package.json 의존성을
10
+ * build가 번들로 묶으므로 복사본은 zip에 넣지 않고 sdk.lib-copy 오류로 옮기는 법을 알린다
11
11
  */
12
12
  export declare function findLegacySdkCopy(projectDir: string, config: ContentConfig): Promise<string | undefined>;
13
13
  /**
14
14
  * 프로젝트(ecdk 프로젝트 폴더)를 검사할 때 build · dev · doctor · check가 함께 쓰는 검사 옵션.
15
- * 파일은 prepareContent가 만든 zip 내용(원본)이고, 모듈 묶기는 build가 하므로 module-src는 보지 않는다.
15
+ * 파일은 prepareContent가 모은 원본(번들 전)이고, 모듈 묶기는 build(Vite)가 하므로 module-src는 보지 않는다.
16
16
  * 프로젝트에만 있는 정보(예: 남은 옛 파일, 템플릿 목록)를 검사에 더할 때는 이 함수에만 더한다.
17
17
  * 그래야 `ecdk validate <프로젝트>`와 `ecdk build` 결과가 어긋나지 않는다.
18
18
  *
19
19
  * `ecdk dev`가 쓰는 상태(.ecdk/settings.json)는 보지 않는다: build · check 결과가 dev에서 무엇을
20
20
  * 저장했는지에 따라 달라지지 않게. templates: 이 CLI가 가진 템플릿 · 버전 (build.template-unknown).
21
21
  * legacyFiles: 남은 옛 파일 (project.legacy-file, elice.config.json · content.json · grading.json).
22
- * legacySdkCopy: 옛 lib/cdk.js 복사본 (sdk.lib-copy)
22
+ * legacySdkCopy: 옛 lib/cdk.js 복사본 (sdk.lib-copy). publicFiles: prepareContent의 public/ 파일 (ref.script-not-public)
23
23
  */
24
- export declare function projectCheckOptions(projectDir: string, config: ContentConfig, extra?: {
24
+ export declare function projectCheckOptions(projectDir: string, config: ContentConfig, extra: {
25
+ publicFiles: Set<string>;
25
26
  zipBytes?: number | undefined;
26
27
  }): Promise<CheckOptions>;
@@ -1,7 +1,7 @@
1
1
  import { access } from 'node:fs/promises';
2
2
  import { posix, join } from 'node:path';
3
3
  import { LEGACY_FILES } from './config.js';
4
- import { SDK_ZIP_PATH, readProjectSdk } from './sdk.js';
4
+ import { LEGACY_SDK_COPY } from './sdk.js';
5
5
  import { knownTemplates } from './templates.js';
6
6
 
7
7
  const exists = p => access(p).then(() => true, () => false);
@@ -18,32 +18,32 @@ async function findLegacyFiles(projectDir, config) {
18
18
  return found;
19
19
  }
20
20
  /**
21
- * 옛 lib/cdk.js 복사본 (ADR 0010 최종 결정): package.json에 @eliceio/cdk가 없는데 원본에 lib/cdk.js가 있으면 그 경로
22
- * (프로젝트 기준). build는 복사본을 그대로 넣고 sdk.lib-copy로 옮기는 법을 알린다
21
+ * 옛 SDK 복사본 (ADR 0010): 원본에 lib/cdk.js가 있으면 그 경로 (프로젝트 기준). SDK는 package.json 의존성을
22
+ * build가 번들로 묶으므로 복사본은 zip에 넣지 않고 sdk.lib-copy 오류로 옮기는 법을 알린다
23
23
  */
24
24
  async function findLegacySdkCopy(projectDir, config) {
25
- const path = posix.join(config.root.replace(/\\/g, '/'), SDK_ZIP_PATH);
26
- if (!(await exists(join(projectDir, path)))) return undefined;
27
- return (await readProjectSdk(projectDir)) === null ? path : undefined;
25
+ const path = posix.join(config.root.replace(/\\/g, '/'), LEGACY_SDK_COPY);
26
+ return (await exists(join(projectDir, path))) ? path : undefined;
28
27
  }
29
28
  /**
30
29
  * 프로젝트(ecdk 프로젝트 폴더)를 검사할 때 build · dev · doctor · check가 함께 쓰는 검사 옵션.
31
- * 파일은 prepareContent가 만든 zip 내용(원본)이고, 모듈 묶기는 build가 하므로 module-src는 보지 않는다.
30
+ * 파일은 prepareContent가 모은 원본(번들 전)이고, 모듈 묶기는 build(Vite)가 하므로 module-src는 보지 않는다.
32
31
  * 프로젝트에만 있는 정보(예: 남은 옛 파일, 템플릿 목록)를 검사에 더할 때는 이 함수에만 더한다.
33
32
  * 그래야 `ecdk validate <프로젝트>`와 `ecdk build` 결과가 어긋나지 않는다.
34
33
  *
35
34
  * `ecdk dev`가 쓰는 상태(.ecdk/settings.json)는 보지 않는다: build · check 결과가 dev에서 무엇을
36
35
  * 저장했는지에 따라 달라지지 않게. templates: 이 CLI가 가진 템플릿 · 버전 (build.template-unknown).
37
36
  * legacyFiles: 남은 옛 파일 (project.legacy-file, elice.config.json · content.json · grading.json).
38
- * legacySdkCopy: 옛 lib/cdk.js 복사본 (sdk.lib-copy)
37
+ * legacySdkCopy: 옛 lib/cdk.js 복사본 (sdk.lib-copy). publicFiles: prepareContent의 public/ 파일 (ref.script-not-public)
39
38
  */
40
- async function projectCheckOptions(projectDir, config, extra = {}) {
39
+ async function projectCheckOptions(projectDir, config, extra) {
41
40
  return {
42
41
  input: 'zip',
43
42
  bundlesModules: true,
44
43
  templates: knownTemplates(),
45
44
  legacyFiles: await findLegacyFiles(projectDir, config),
46
45
  legacySdkCopy: await findLegacySdkCopy(projectDir, config),
46
+ publicFiles: [...extra.publicFiles],
47
47
  ...(extra.zipBytes !== undefined ? {
48
48
  zipBytes: extra.zipBytes
49
49
  } : {})
@@ -5,13 +5,14 @@ export interface SandboxReport {
5
5
  /** 모듈 스크립트를 묶어 넣은 HTML */
6
6
  pages: string[];
7
7
  }
8
- /** HTML의 모듈 스크립트(src)를 묶어 본문으로 넣는다. 바뀐 파일만 새로 만들어 돌려준다 */
9
- export declare function inlineModuleScripts(files: SourceFile[],
10
- /** esbuild 작업 폴더 (기본: 실행 폴더). 테스트에서 프로젝트 폴더 안 실행을 흉내 낼 때 */
11
- opts?: {
8
+ export interface InlineOptions {
9
+ /** esbuild 작업 폴더 (기본: 실행 폴더). 테스트에서 프로젝트 폴더 안 실행을 흉내 낼 때 */
12
10
  workingDir?: string | undefined;
13
11
  minify?: boolean | undefined;
14
- }): Promise<{
12
+ sourcemap?: boolean | undefined;
13
+ }
14
+ /** HTML의 모듈 스크립트(src)를 묶어 본문으로 넣는다. 바뀐 파일만 새로 만들어 돌려준다 */
15
+ export declare function inlineModuleScripts(files: SourceFile[], opts?: InlineOptions): Promise<{
15
16
  files: SourceFile[];
16
17
  report: SandboxReport;
17
18
  }>;
@@ -13,11 +13,11 @@ import { classifyRef } from '../rules/refs.js';
13
13
  * (일반 `<script src>` · `<link rel="stylesheet">` · `<img>`는 CORS를 쓰지 않아 그대로 된다.)
14
14
  * 헤더가 `allow-same-origin`을 주면 같은 출처 요청이라 막히지 않지만, 어느 쪽이든 화면이 뜨도록 묶는다.
15
15
  *
16
- * build는 zip에 넣기 전에 HTML마다:
17
- * - `<script type="module" src="상대경로">`를 esbuild로 하나로 묶어 `<script type="module">` 본문으로 넣는다
18
- * (zip 안 파일만 묶음. `import.meta.url`은 원래 파일 주소로 바꿔 상대경로 계산이 그대로 맞게).
16
+ * build(Vite 플러그인 engines/vite)는 Vite가 만든 결과물에서 zip에 넣기 전에 HTML마다:
17
+ * - `<script type="module" src="상대경로">`(Vite가 나눈 chunk)를 esbuild로 하나로 묶어 `<script type="module">` 본문으로 넣는다
18
+ * (결과물 안 파일만 묶음. `import.meta.url`은 원래 파일 주소로 바꿔 상대경로 계산이 그대로 맞게).
19
19
  * - zip 안 JSON(metadata.json 제외, 작성자가 넣은 데이터 파일)을 페이지에 넣고 `fetch`가 그 주소를 받으면 넣어 둔 내용을 돌려준다.
20
- * 원본 JS · JSON 파일은 zip에 그대로 둔다 (`ecdk dev` · 다른 참조용).
20
+ * 묶어 넣은 chunk 파일은 플러그인이 결과물에서 뺀다.
21
21
  */
22
22
  const encoder = new TextEncoder();
23
23
  const decoder = new TextDecoder();
@@ -53,6 +53,12 @@ function zipFiles(byPath, page) {
53
53
  namespace: 'zip'
54
54
  };
55
55
  }
56
+ // Bare specifiers left here were not resolved by Vite (package not installed)
57
+ if (/^(?:@[\w.-]+\/)?[\w.-]+(?:\/|$)/.test(args.path) && !/^\.\.?\//.test(args.path)) return {
58
+ errors: [{
59
+ text: `패키지를 찾지 못했습니다: ${args.path}. package.json dependencies에 넣고 npm install을 실행해 주세요`
60
+ }]
61
+ };
56
62
  if (classifyRef(args.path) !== 'local') return {
57
63
  errors: [{
58
64
  text: `zip 안 파일만 묶을 수 있습니다: ${args.path}`
@@ -100,6 +106,12 @@ async function bundle(entry, page, byPath, opts) {
100
106
  } : {}),
101
107
  // minify를 켜면 실제로 실행되는 묶음 코드를 줄인다 (원본 JS는 이제 실행되지 않음)
102
108
  minify: opts.minify === true,
109
+ // sourcemap: 묶은 본문 끝에 inline map (chunk의 inline map을 이어 받아 원본 파일을 가리킴)
110
+ ...(opts.sourcemap ? {
111
+ sourcemap: 'inline'
112
+ } : {}),
113
+ // 라이선스 주석(/*! · @license · @preserve)은 줄여도 묶음 끝에 모아 남긴다 (넣은 라이브러리의 고지 의무)
114
+ legalComments: 'eof',
103
115
  bundle: true,
104
116
  format: 'esm',
105
117
  target: 'es2022',
@@ -129,9 +141,15 @@ function jsonPrelude(files, page) {
129
141
  const json = escapeInline(JSON.stringify(data));
130
142
  return `<script>(()=>{const d=${json},b=document.baseURI,m=new Map(Object.entries(d).map(([k,v])=>[new URL(k,location.href).href,v])),f=window.fetch.bind(window);window.fetch=(i,o)=>{try{const u=new URL(typeof i==='string'||i instanceof URL?i:i.url,b).href.replace(/[?#].*$/,'');if(m.has(u)&&(!o||!o.method||o.method.toUpperCase()==='GET'))return Promise.resolve(new Response(JSON.stringify(m.get(u)),{headers:{'Content-Type':'application/json'}}))}catch{}return f(i,o)}})();</script>`;
131
143
  }
144
+ /**
145
+ * `crossorigin` 속성을 뗀다: Vite가 `<script type="module">` · `<link rel="stylesheet">`에 붙이는데,
146
+ * 콘텐츠 출처가 null인 LXP에서는 CORS 모드 요청이 되어 스타일시트까지 막힌다
147
+ */
148
+ function stripCrossorigin(html) {
149
+ return html.replace(/<(?:link|script)\b[^>]*>/gi, tag => tag.replace(/\s+crossorigin(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s>]+))?(?=[\s/>])/gi, ''));
150
+ }
132
151
  /** HTML의 모듈 스크립트(src)를 묶어 본문으로 넣는다. 바뀐 파일만 새로 만들어 돌려준다 */
133
- async function inlineModuleScripts(files, /** esbuild 작업 폴더 (기본: 실행 폴더). 테스트에서 프로젝트 폴더 안 실행을 흉내 낼 때 */
134
- opts = {}) {
152
+ async function inlineModuleScripts(files, opts = {}) {
135
153
  const byPath = new Map(files.map(f => [f.path, f]));
136
154
  const pages = [];
137
155
  const out = [];
@@ -140,7 +158,8 @@ opts = {}) {
140
158
  out.push(f);
141
159
  continue;
142
160
  }
143
- const html = decoder.decode(f.data);
161
+ const original = decoder.decode(f.data);
162
+ const html = stripCrossorigin(original);
144
163
  // 주석 안의 스크립트(<!-- <script type="module" src="old.js"> -->)는 실행되지 않으므로 묶지 않는다
145
164
  const comments = [...html.matchAll(/<!--[\s\S]*?-->/g)].map(c => [c.index, c.index + c[0].length]);
146
165
  const inComment = at => comments.some(([from, to]) => at > from && at < to);
@@ -151,7 +170,10 @@ opts = {}) {
151
170
  return attr(a, 'type')?.toLowerCase() === 'module' && src && classifyRef(src) === 'local';
152
171
  });
153
172
  if (scripts.length === 0) {
154
- out.push(f);
173
+ out.push(html === original ? f : {
174
+ ...f,
175
+ data: encoder.encode(html)
176
+ });
155
177
  continue;
156
178
  }
157
179
  let next = '';
package/es/core/sdk.d.ts CHANGED
@@ -1,12 +1,12 @@
1
- import type { SourceFile } from './collect.js';
2
1
  /**
3
- * SDK(@eliceio/cdk)는 프로젝트 package.json 의존성이다 (ADR 0010 최종 결정). LXP sandbox에는 node_modules가 없으므로
4
- * build · dev가 설치된 SDK의 UMD 빌드를 zip의 lib/cdk.js로 넣는다 (화면 키트 lib/elice-content.js가 같은 폴더에서 부름).
5
- * 키트(lib/elice-content.js · .css · cdk-mock.js)는 ecdk create가 복사한 프로젝트 lib/ 그대로다.
2
+ * SDK(@eliceio/cdk)는 프로젝트 package.json 의존성이다 (ADR 0010). 화면 키트(lib/elice-content.js)가
3
+ * `import('@eliceio/cdk')`로 부르고, ecdk build(Vite)가 node_modules에서 찾아 화면 코드와 함께 번들로 묶는다.
4
+ * SDK 파일을 zip에 따로 넣거나 복사하지 않는다. metadata.json build.sdk는 설치된 패키지 버전
5
+ * (node_modules/@eliceio/cdk/package.json).
6
6
  */
7
7
  export declare const SDK_PACKAGE = "@eliceio/cdk";
8
- /** zip 안 SDK 파일 */
9
- export declare const SDK_ZIP_PATH = "lib/cdk.js";
8
+ /** 옛 방식의 SDK 복사본 (원본에 있으면 sdk.lib-copy 오류, zip에는 넣지 않는다) */
9
+ export declare const LEGACY_SDK_COPY = "lib/cdk.js";
10
10
  export declare const INSTALL_COMMAND = "npm install";
11
11
  export declare const UPDATE_COMMAND = "npm update @eliceio/cdk";
12
12
  export interface InstalledSdk {
@@ -22,18 +22,7 @@ export interface ProjectSdk {
22
22
  }
23
23
  /** package.json에 적은 SDK 범위 (dependencies → devDependencies). 없으면 undefined */
24
24
  export declare function declaredSdkRange(pkg: Record<string, unknown> | null): string | undefined;
25
- /**
26
- * 프로젝트가 SDK를 패키지로 쓰는지와 설치 상태. package.json에 @eliceio/cdk가 없으면 null
27
- * (옛 lib/cdk.js 복사본 프로젝트이거나 SDK를 쓰지 않는 자료: build는 원본 그대로)
28
- */
25
+ /** 프로젝트가 SDK를 패키지로 쓰는지와 설치 상태. package.json에 @eliceio/cdk가 없으면 null (SDK를 쓰지 않는 자료이거나 옛 프로젝트) */
29
26
  export declare function readProjectSdk(projectDir: string): Promise<ProjectSdk | null>;
30
27
  /** SDK가 설치되지 않았을 때 문구 */
31
28
  export declare function missingSdkMessage(): string;
32
- /**
33
- * zip lib/cdk.js 머리말. build.sdk는 이 머리말에서 읽는다 (core/manifest.ts).
34
- * SDK는 LXP 화면과 postMessage(설정 저장 결과 · 페이지 이동)로 이야기하므로 두 규칙을 이 파일에서만 끈다.
35
- * 두 규칙은 client 검사라 서버 업로드 검사와는 상관없다
36
- */
37
- export declare function sdkHeader(version: string): string;
38
- /** 설치된 SDK의 UMD 빌드에 머리말을 붙인 zip 파일 lib/cdk.js */
39
- export declare function sdkZipFile(sdk: InstalledSdk): Promise<SourceFile>;
package/es/core/sdk.js CHANGED
@@ -2,15 +2,14 @@ import { readFile } from 'node:fs/promises';
2
2
  import { join, resolve, dirname } from 'node:path';
3
3
 
4
4
  /**
5
- * SDK(@eliceio/cdk)는 프로젝트 package.json 의존성이다 (ADR 0010 최종 결정). LXP sandbox에는 node_modules가 없으므로
6
- * build · dev가 설치된 SDK의 UMD 빌드를 zip의 lib/cdk.js로 넣는다 (화면 키트 lib/elice-content.js가 같은 폴더에서 부름).
7
- * 키트(lib/elice-content.js · .css · cdk-mock.js)는 ecdk create가 복사한 프로젝트 lib/ 그대로다.
5
+ * SDK(@eliceio/cdk)는 프로젝트 package.json 의존성이다 (ADR 0010). 화면 키트(lib/elice-content.js)가
6
+ * `import('@eliceio/cdk')`로 부르고, ecdk build(Vite)가 node_modules에서 찾아 화면 코드와 함께 번들로 묶는다.
7
+ * SDK 파일을 zip에 따로 넣거나 복사하지 않는다. metadata.json build.sdk는 설치된 패키지 버전
8
+ * (node_modules/@eliceio/cdk/package.json).
8
9
  */
9
10
  const SDK_PACKAGE = '@eliceio/cdk';
10
- /** zip 안 SDK 파일 */
11
- const SDK_ZIP_PATH = 'lib/cdk.js';
12
- /** 설치된 SDK 안의 UMD 빌드 */
13
- const SDK_UMD = 'umd/index.js';
11
+ /** 옛 방식의 SDK 복사본 (원본에 있으면 sdk.lib-copy 오류, zip에는 넣지 않는다) */
12
+ const LEGACY_SDK_COPY = 'lib/cdk.js';
14
13
  const INSTALL_COMMAND = 'npm install';
15
14
  const UPDATE_COMMAND = `npm update ${SDK_PACKAGE}`;
16
15
  async function readJson(path) {
@@ -49,10 +48,7 @@ function declaredSdkRange(pkg) {
49
48
  }
50
49
  return undefined;
51
50
  }
52
- /**
53
- * 프로젝트가 SDK를 패키지로 쓰는지와 설치 상태. package.json에 @eliceio/cdk가 없으면 null
54
- * (옛 lib/cdk.js 복사본 프로젝트이거나 SDK를 쓰지 않는 자료: build는 원본 그대로)
55
- */
51
+ /** 프로젝트가 SDK를 패키지로 쓰는지와 설치 상태. package.json에 @eliceio/cdk가 없으면 null (SDK를 쓰지 않는 자료이거나 옛 프로젝트) */
56
52
  async function readProjectSdk(projectDir) {
57
53
  const range = declaredSdkRange(await readJson(join(projectDir, 'package.json')));
58
54
  if (range === undefined) return null;
@@ -65,31 +61,5 @@ async function readProjectSdk(projectDir) {
65
61
  function missingSdkMessage() {
66
62
  return `${SDK_PACKAGE} 패키지를 찾지 못했습니다 (node_modules에 없음). 프로젝트 폴더에서 ${INSTALL_COMMAND}을 실행해 주세요.`;
67
63
  }
68
- /**
69
- * zip lib/cdk.js 머리말. build.sdk는 이 머리말에서 읽는다 (core/manifest.ts).
70
- * SDK는 LXP 화면과 postMessage(설정 저장 결과 · 페이지 이동)로 이야기하므로 두 규칙을 이 파일에서만 끈다.
71
- * 두 규칙은 client 검사라 서버 업로드 검사와는 상관없다
72
- */
73
- function sdkHeader(version) {
74
- return [`/* ${SDK_PACKAGE} ${version} — UMD. Added by ecdk build from node_modules/${SDK_PACKAGE}; do not edit. */`, '// ecdk-ignore-next-line api.parent-access sec.postmessage-wildcard', ''].join('\n');
75
- }
76
- /** 설치된 SDK의 UMD 빌드에 머리말을 붙인 zip 파일 lib/cdk.js */
77
- async function sdkZipFile(sdk) {
78
- const umd = join(sdk.dir, ...SDK_UMD.split('/'));
79
- let data;
80
- try {
81
- data = new Uint8Array(await readFile(umd));
82
- } catch {
83
- throw new Error(`${SDK_PACKAGE} ${sdk.version}에 UMD 빌드(${SDK_UMD})가 없습니다. ${INSTALL_COMMAND}으로 다시 설치해 주세요.`);
84
- }
85
- const head = new TextEncoder().encode(sdkHeader(sdk.version));
86
- const joined = new Uint8Array(head.byteLength + data.byteLength);
87
- joined.set(head);
88
- joined.set(data, head.byteLength);
89
- return {
90
- path: SDK_ZIP_PATH,
91
- data: joined
92
- };
93
- }
94
64
 
95
- export { INSTALL_COMMAND, SDK_PACKAGE, SDK_ZIP_PATH, UPDATE_COMMAND, declaredSdkRange, missingSdkMessage, readProjectSdk, sdkHeader, sdkZipFile };
65
+ export { INSTALL_COMMAND, LEGACY_SDK_COPY, SDK_PACKAGE, UPDATE_COMMAND, declaredSdkRange, missingSdkMessage, readProjectSdk };