Repository navigation
fix(extractor): preserve numeric template interpolations - #785
Merged
Merged
Conversation
Refs #686 Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
Refs #686 Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
Refs #686 Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
Refs #686 Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
Refs #686; stack #784 on #783 and #781. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
Refs #686 Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
Contributor
Changepacks@devup-ui/wasm@1.0.83 → 1.0.84 - bindings/devup-ui-wasm/package.jsonPatch
@devup-ui/bun-plugin@1.0.22 → 1.0.23 - packages/bun-plugin/package.jsonPatch
@devup-ui/components@0.1.60 → 0.1.61 - packages/components/package.jsonPatch
@devup-ui/eslint-plugin@1.0.22 → 1.0.23 - packages/eslint-plugin/package.jsonPatch
@devup-ui/next-plugin@1.0.90 → 1.0.91 - packages/next-plugin/package.jsonPatch
@devup-ui/plugin-utils@1.0.17 → 1.0.18 - packages/plugin-utils/package.jsonPatch
@devup-ui/react@1.0.44 → 1.0.45 - packages/react/package.jsonPatch
@devup-ui/reset-css@1.0.31 → 1.0.32 - packages/reset-css/package.jsonPatch
@devup-ui/rsbuild-plugin@1.0.67 → 1.0.68 - packages/rsbuild-plugin/package.jsonPatch
@devup-ui/vite-plugin@1.0.73 → 1.0.74 - packages/vite-plugin/package.jsonPatch
@devup-ui/webpack-plugin@1.0.71 → 1.0.72 - packages/webpack-plugin/package.jsonPatch
|
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.
Refs #686 (W69: 숫자처럼 보이는 템플릿 보간의 값/부작용 보존).
main의a6ecc125에서 새로 시작한 독립 수정 PR이며 선행 병합이 필요한 PR은 없습니다.요약
shared-template-main-path.json과722-gate-review.md에서 발견한 공통 숫자 템플릿 변환 오류를 수정합니다. W69에서도 수정 전 main을 새로 빌드하여 독립적으로 재현했습니다.0.${(trace.push('value'), 5)}를 정적0으로 읽었습니다. 잘못된 CSS와 사라진 부작용을 함께 고칩니다.'05'는 그대로 보존하고, 숫자만 JavaScript 숫자 문자열 규칙으로 변환합니다.Patch입니다.동작
실제 최종 WASM + React SSR 프로브의 per-file CSS 출력입니다.
한 번 렌더링하면 trace는 정확히
["value"]입니다. 변수 보간은 다음 렌더링에서0.5에서0.7로 바뀌며, Box scalar / styled 정의 / 반응형 배열에 같은 기존 CSS 변수 경로를 사용합니다.singleCss모드도 같은 결과를 검증했습니다.0.${5}와 중첩 리터럴은 정확히.5로 정적 추출됩니다.0.${'05'}는.05입니다.inf별칭으로 잘못 접히지 않도록 템플릿 숫자 경계에서만 보수적으로 거절합니다. 실제`"value:${+`\x69nf`}"`결과는value:NaN이며value:Infinity가 아닙니다.새로 생기는 오류
새 오류 형식은 추가하지 않습니다. 다만 이전에 잘못 정적
0으로 처리되던 **독립css({ opacity: dynamicTemplate })**는 이제 기존의 위치가 있는 빌드 오류로 보고됩니다. 독립 클래스 문자열은 동적 값을 전달할 요소를 소유하지 않으므로 런타임 스타일링으로 우회하지 않습니다.실제 프로브 예시:
templates.tsx:1:150: css() cannot use ... at build time: its values must be literals, theme tokens or constants, or be computed from them. Box / styled / 반응형 요소 값은 오류 대신 기존 CSS 변수를 사용합니다.남는 한계
빌드에서 알 수 없는 독립
css()값의 제약은 유지합니다. 템플릿과 관계없는 메타데이터/키/전역 구조 입력 및 일반 강제 변환 동작은 범위를 넓히지 않고 그대로 두었습니다. CI 통과 후 main에서 별도 프로브 36개를 실행해 styleOrder, 배열/문자열 키, 독립 문자열 unary 강제 변환, imports/fontFaces/selector params/globalStyle 입력의 기존 문제를 재현했으며 후속 범위는 코디네이터가 결정합니다. 시험한 동적 layer 입력은 기존 위치가 있는 오류로 안전하게 거절되었습니다.검증
RED: 수정 전 main에서 새 Rust 103개 중 18 통과 / 85 실패. 실제 생성 렌더러의 12개 부작용 검증이 모두 trace/값 손실을 관찰했습니다.
최종 기본 스택 /
CARGO_BUILD_JOBS=2: Rust workspace 4,110 통과 / 0 실패, 템플릿 관련 147개 포함. Rust 1.99 strict clippy와 fmt check 통과.기존 스냅샷 변경 및
.snap.new없음. 새 WASM 빌드와 루트 빌드 통과.최종 공개 WASM + 실제 React SSR: 기본 행렬 72개(정상 추출/SSR 64개, 기존 css 빌드 오류 8개), escaped unary 회귀 6개 모두 통과. 각 CSS 모드의 반복 추출 코드/CSS가 바이트 단위로 동일합니다.
최종 Bun: 5,909 통과 / 0 실패, 함수/라인 커버리지 100%.
전체 CI-unset/default-stack pre-commit hook 통과: 실제 커밋 hook 564초 통과, 별도 foreground 전체 hook 재검증 603초/최대 4.63 GiB(12 GiB watchdog), lint 0 오류/기존 경고 9개, Bun 5,909 통과/0 실패/100%.
추가한 production 코드 중 LLVM에 매핑된 24개 라인 모두 커버되며 추가 라인 miss는 0개입니다. Windows 보통 너비 LLVM 커버리지는 main에서도 100% 미만인 알려진 호스트 차이이므로 원격 Linux
--fail-under 100및 전체 CI를 최종 기준으로 확인합니다.원격 CI 성공: 39001603058, head
2f989b6a4809b1f6aea7bf51ba5e76d621dccae1. Linux Rust 커버리지 100.00% (12,391/12,391), Bun 5,909 통과/0 실패, 함수/라인 100%.publish,landing-next-e2e,benchmark,vinext-rsc-css-e2e네 작업 모두 성공했습니다.2026-10-17: fix(extractor): preserve leading JSX compiler pragmas #784(
ecb034ab, fix(next): deliver complete webpack CSS across compilers and cached builds #783·fix(next): support JavaScript JSX and webpack source map objects #781·mainb4c143b1포함) 위에 실제 두 부모 merge(33c1582b)로 쌓았습니다. fix(extractor): preserve leading JSX compiler pragmas #784 바로 다음에 병합해야 합니다. 충돌은libs/extractor/src/lib.rs모듈 목록 한 곳뿐이라 양쪽 모듈(numeric_template_tests, parsing, pragma 테스트 3개)을 모두 남겼습니다. main에 들어온 #722가 styled 컴포넌트를forwardRef로 감싸게 되어, 생성된 renderer를 직접 실행하는 이 PR의 테스트 harness에forwardRef대역(ref null로 한 번 렌더)을 추가했습니다(제품 코드 변경 없음). 전체 hook(lint, Rust, Bun 5,930 pass) 통과.