fix(react-zpl): zpl-core를 번들하지 않고 external 의존성으로 유지 - #27
Merged
Conversation
rolldown external에 react/react-dom만 있어 @zpl-kit/zpl-core가 런타임 JS에 번들됐다. 반면 .d.ts와 package.json은 zpl-core를 external로 참조 → 코드가 이중 포함되고 런타임·타입·의존성 선언이 어긋났다. - rolldown external에 /^@zpl-kit\// 추가 → 런타임도 zpl-core를 import로 남김 - workspace:* → workspace:^ (발행 시 ^0.1.0 범위 핀, 정확 버전 고정 해소) 빌드 후 dist/index.js가 zpl-core 심볼을 인라인하지 않고 import하는 것과 42개 테스트 통과를 확인. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
문제
apps/react-zpl의 빌드가 두 도구로 나뉘는데(런타임rolldown, 타입tsc), external 처리가 어긋나 있었습니다.@zpl-kit/zpl-core가dist/index.js에 번들됐습니다..d.ts:@zpl-kit/zpl-core를 external로 import.@zpl-kit/zpl-core를 런타임 의존성으로 선언.결과적으로 zpl-core 코드가 이중 포함되고, 런타임·타입·의존성 선언 셋이 불일치했습니다.
변경
rolldown.config.ts— external에/^@zpl-kit\//추가 → 런타임도 zpl-core를 import로 남김package.json—workspace:*→workspace:^(발행 시 정확 버전 대신^0.1.0범위 핀)검증
dist/index.js가 zpl-core 심볼을 인라인하지 않고import { renderLabel } from "@zpl-kit/zpl-core"하는 것 확인pnpm pack으로 발행될dependencies가"@zpl-kit/zpl-core": "^0.1.0"인 것 확인type-check·format:check·lint(경고 0) 통과