Chore: Seperate vanilla extract API to ./compat#219
Conversation
🦋 Changeset detectedLatest commit: 90cde80 The changes in this PR will be included in the next version bump. This PR includes changesets to release 7 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
WalkthroughThis change removes the Changes
Sequence Diagram(s)sequenceDiagram
participant ReactApp
participant MinchoCSS
ReactApp->>MinchoCSS: import { css, globalCss }
ReactApp->>MinchoCSS: use css() and globalCss() for styling
sequenceDiagram
participant BabelPlugin
participant MinchoCSS
BabelPlugin->>MinchoCSS: registerImportMethod("rules")
BabelPlugin->>MinchoCSS: transform styled components using "rules"
sequenceDiagram
participant CompatModule
participant VanillaExtract
participant LocalCSS
CompatModule->>VanillaExtract: re-export CSS utilities and types
CompatModule->>LocalCSS: re-export renamed css functions (style, globalStyle, styleVariants)
CompatModule->>MinchoCSSRules: re-export rules as recipe
Possibly related PRs
Poem
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
yarn install v1.22.22 ✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
|
Triggered from #219 by @black7375. Checking if we can fast forward Target branch ( commit e770e4c9d801828b548ee8bf44c6a499ccd8255e (HEAD -> main, origin/main)
Author: alstjr7375 <alstjr7375@daum.net>
Date: Sat Jun 7 03:58:05 2025 +0900
Chore: Seperate package check CIPull request ( commit 5b56ad0b8dc12de8f892f3cc83bf984500f9164c (pull_request/ve-compat-entry)
Author: alstjr7375 <alstjr7375@daum.net>
Date: Mon Jun 9 00:00:00 2025 +0900
Chore: Seperate vanilla extract API to `./compat`It is possible to fast forward |
There was a problem hiding this comment.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (9)
examples/react-swc/src/App.css.ts(3 hunks)examples/react-swc/src/index.css.ts(3 hunks)packages/babel/src/styled.ts(1 hunks)packages/babel/src/utils.ts(1 hunks)packages/css/package.json(1 hunks)packages/css/src/css/index.ts(2 hunks)packages/css/src/index.ts(2 hunks)packages/css/src/rules/index.ts(0 hunks)packages/css/vite.config.ts(1 hunks)
💤 Files with no reviewable changes (1)
- packages/css/src/rules/index.ts
🧰 Additional context used
🧠 Learnings (9)
📓 Common learnings
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
examples/react-swc/src/index.css.ts (2)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
packages/babel/src/utils.ts (1)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
packages/babel/src/styled.ts (1)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
packages/css/vite.config.ts (2)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
examples/react-swc/src/App.css.ts (2)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
packages/css/src/css/index.ts (3)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#110
File: packages/css/src/rules/types.ts:25-29
Timestamp: 2024-09-29T14:13:13.977Z
Learning: For `ToggleVariantMap`, only the `true` state is needed for toggle variants.
Learnt from: black7375
PR: mincho-js/mincho#110
File: packages/css/src/rules/types.ts:25-29
Timestamp: 2024-10-09T13:00:38.449Z
Learning: For `ToggleVariantMap`, only the `true` state is needed for toggle variants.
packages/css/package.json (2)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
packages/css/src/index.ts (2)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
🧬 Code Graph Analysis (2)
examples/react-swc/src/index.css.ts (2)
packages/css/src/index.ts (1)
globalCss(28-28)packages/css/src/css/index.ts (1)
globalCss(18-40)
examples/react-swc/src/App.css.ts (1)
packages/css/src/css/index.ts (2)
globalCss(18-40)css(104-106)
🔇 Additional comments (9)
examples/react-swc/src/index.css.ts (1)
1-69: LGTM! Clean API migration fromglobalStyletoglobalCss.The migration is consistent across all global style declarations, maintaining the same function signatures and styling logic while using the updated API names.
packages/babel/src/utils.ts (1)
73-76: LGTM! Correct addition of new extraction APIs.The new API names (
css,cssVariants,globalCss,rules) are properly added to the extraction list, ensuring babel tooling recognizes these identifiers for CSS extraction.packages/css/vite.config.ts (1)
13-14: LGTM! Proper addition of compat entry point.The build configuration correctly adds the new
compatentry point, enabling separate builds for the compatibility module as intended by the PR objectives.examples/react-swc/src/App.css.ts (1)
1-49: LGTM! Consistent API migration from aliases to direct function names.The migration from
globalStyle/styletoglobalCss/cssis applied consistently throughout the file while preserving all styling logic and export names.packages/babel/src/styled.ts (1)
58-58: LGTM! Correct migration fromrecipealias torules.The change from
"recipe"to"rules"aligns with the broader API migration to remove aliases in favor of direct function names, ensuring the babel plugin imports the correct identifier.packages/css/src/css/index.ts (2)
203-203: LGTM: Test updated to use direct API.The test correctly uses
cssinstead of the removedstylealias, maintaining consistency with the API cleanup.
244-244: LGTM: Test updated to use direct API.The test correctly uses
cssinstead of the removedstylealias, maintaining consistency with the API cleanup.packages/css/package.json (1)
45-54: LGTM: Compat export properly configured.The new
./compatexport follows the established pattern with proper ESM/CJS dual-mode support and type declarations. This correctly supports the separation of Vanilla Extract API to the compat directory.packages/css/src/index.ts (1)
1-6: LGTM: Type re-exports improve module organization.Converting from
import typetoexport typefor CSS-related types improves the module's public API by making these types directly available to consumers.
| export { globalCss, css, cssVariants } from "./css/index.js"; | ||
| export { rules } from "./rules/index.js"; |
There was a problem hiding this comment.
💡 Verification agent
🧩 Analysis chain
Verify removed exports are available in compat module.
The export reduction correctly removes Vanilla Extract aliases (globalStyle, style, styleVariants) and recipe/createRuntimeFn, aligning with the PR objective to separate these APIs. However, please ensure these removed functions are properly exported from the new ./compat module for backward compatibility.
🏁 Script executed:
#!/bin/bash
# Description: Verify that removed exports are available in the compat module
# Expected: compat.ts should export the removed aliases and functions
# Check if compat.ts exists and contains the expected exports
fd -t f "compat.ts" packages/css/src/ --exec cat {} \; | head -20
# Search for the removed function exports in compat module
rg -A 3 "export.*(?:globalStyle|style|styleVariants|recipe|createRuntimeFn)" packages/css/src/Length of output: 699
Missing backward‐compat exports in the compat module
I didn’t find a compat.ts (or compat/index.ts) exporting the removed aliases and functions. To preserve backwards compatibility, please add or update that file under packages/css/src/ so it re‐exports:
globalStyle(alias forglobalCss)style(alias forcss)styleVariants(alias forcssVariants)recipe(from./rules)createRuntimeFn(from./rules/createRuntimeFn)
Example implementation:
// packages/css/src/compat.ts
export { globalCss as globalStyle, css as style, cssVariants as styleVariants } from "./css/index.js";
export { recipe } from "./rules/index.js";
export { createRuntimeFn } from "./rules/createRuntimeFn.js";Please ensure this file is included in your package entrypoints so consumers relying on the old API continue to work.
🤖 Prompt for AI Agents
In packages/css/src/compat.ts, create a new file that re-exports the
backward-compatible aliases and functions: export globalCss as globalStyle, css
as style, and cssVariants as styleVariants from "./css/index.js"; export recipe
from "./rules/index.js"; and export createRuntimeFn from
"./rules/createRuntimeFn.js". Then update the package entrypoints to include
this compat.ts file so that consumers relying on the old API continue to work
without issues.
5b56ad0 to
9fcf794
Compare
|
Triggered from #219 by @black7375. Checking if we can fast forward Target branch ( commit e770e4c9d801828b548ee8bf44c6a499ccd8255e (HEAD -> main, origin/main)
Author: alstjr7375 <alstjr7375@daum.net>
Date: Sat Jun 7 03:58:05 2025 +0900
Chore: Seperate package check CIPull request ( commit 9fcf794f490ae60e4d0632195f10ddfa70a7d5d4 (pull_request/ve-compat-entry)
Author: alstjr7375 <alstjr7375@daum.net>
Date: Mon Jun 9 00:00:00 2025 +0900
Chore: Seperate vanilla extract API to `./compat`It is possible to fast forward |
9fcf794 to
90cde80
Compare
|
Triggered from #219 by @black7375. Checking if we can fast forward Target branch ( commit e770e4c9d801828b548ee8bf44c6a499ccd8255e (HEAD -> main, origin/main)
Author: alstjr7375 <alstjr7375@daum.net>
Date: Sat Jun 7 03:58:05 2025 +0900
Chore: Seperate package check CIPull request ( commit 90cde801cc0133649869bfed9c2e053aa600f6db (pull_request/ve-compat-entry)
Author: alstjr7375 <alstjr7375@daum.net>
Date: Sat Jul 19 21:37:30 2025 +0900
Chore: Seperate vanilla extract API to `./compat`It is possible to fast forward |
|
@coderabbitai full review |
✅ Actions performedFull review triggered. |
|
@coderabbitai full review |
✅ Actions performedFull review triggered. |
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (1)
packages/babel/src/utils.ts (1)
70-108: Consider cleaning up duplicate entries.The
extractionAPIsarray contains duplicate entries for vanilla-extract APIs (lines 78-95 and 92-105). While this doesn't break functionality, it could be cleaned up for maintainability.export const extractionAPIs = [ // @mincho-js/css "mincho$", "css", "cssVariants", "globalCss", "rules", // @vanilla-extract/css "style", "styleVariants", "globalStyle", "createTheme", "createGlobalTheme", "createThemeContract", "createGlobalThemeContract", "assignVars", "createVar", "fallbackVar", "fontFace", "globalFontFace", "keyframes", "globalKeyframes", - "style", - "styleVariants", - "globalStyle", - "createTheme", - "createGlobalTheme", - "createThemeContract", - "createGlobalThemeContract", - "assignVars", - "createVar", - "fallbackVar", - "fontFace", - "globalFontFace", - "keyframes", - "globalKeyframes", // @vanilla-extract/recipes "recipe" ];
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (11)
.changeset/calm-heads-care.md(1 hunks)examples/react-swc/src/App.css.ts(3 hunks)examples/react-swc/src/index.css.ts(3 hunks)packages/babel/src/styled.ts(1 hunks)packages/babel/src/utils.ts(1 hunks)packages/css/package.json(1 hunks)packages/css/src/compat.ts(1 hunks)packages/css/src/css/index.ts(2 hunks)packages/css/src/index.ts(2 hunks)packages/css/src/rules/index.ts(0 hunks)packages/css/vite.config.ts(1 hunks)
💤 Files with no reviewable changes (1)
- packages/css/src/rules/index.ts
🧰 Additional context used
🧠 Learnings (11)
📓 Common learnings
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
packages/css/vite.config.ts (2)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
examples/react-swc/src/index.css.ts (1)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
packages/babel/src/styled.ts (1)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
packages/babel/src/utils.ts (1)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
examples/react-swc/src/App.css.ts (2)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
packages/css/src/css/index.ts (3)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#110
File: packages/css/src/rules/types.ts:25-29
Timestamp: 2024-09-29T14:13:13.977Z
Learning: For `ToggleVariantMap`, only the `true` state is needed for toggle variants.
Learnt from: black7375
PR: mincho-js/mincho#110
File: packages/css/src/rules/types.ts:25-29
Timestamp: 2024-10-09T13:00:38.449Z
Learning: For `ToggleVariantMap`, only the `true` state is needed for toggle variants.
packages/css/package.json (2)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
.changeset/calm-heads-care.md (1)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
packages/css/src/compat.ts (2)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
packages/css/src/index.ts (2)
Learnt from: black7375
PR: mincho-js/mincho#113
File: packages/css/src/index.ts:33-33
Timestamp: 2024-10-09T13:00:38.449Z
Learning: `recipe` is properly exported from './rules' in `packages/css/src/rules/index.ts`.
Learnt from: black7375
PR: mincho-js/mincho#134
File: packages/transform-to-vanilla/src/transform.ts:49-51
Timestamp: 2024-12-03T11:16:32.528Z
Learning: In projects that target both CommonJS and ES modules, adjusting the TypeScript `module` option may not be feasible. Therefore, using `@ts-ignore` comments to suppress TypeScript errors related to `import.meta` is acceptable.
🧬 Code Graph Analysis (1)
examples/react-swc/src/App.css.ts (3)
packages/css/src/compat.ts (2)
globalCss(22-22)css(23-23)packages/css/src/index.ts (2)
globalCss(28-28)css(28-28)packages/css/src/css/index.ts (2)
globalCss(18-40)css(104-106)
🔇 Additional comments (12)
.changeset/calm-heads-care.md (1)
1-7: LGTM! Clear changeset documentation.The changeset properly documents the minor version updates for both affected packages and clearly describes the separation of the vanilla extract API to the
./compatdirectory.examples/react-swc/src/index.css.ts (2)
1-1: LGTM! Proper migration to canonical API.The import has been correctly updated from
globalStyletoglobalCss, aligning with the removal of legacy aliases from the main package exports.
3-69: LGTM! Consistent function call updates.All
globalStylefunction calls have been systematically replaced withglobalCsswhile preserving the CSS content and logic. This change properly reflects the API standardization.packages/css/vite.config.ts (1)
13-14: LGTM! Proper multi-entry build configuration.The build configuration correctly adds the new
compatentry point while enabling the mainindexentry. This supports the separation of the vanilla extract API into a dedicated compatibility module.packages/babel/src/utils.ts (1)
73-76: LGTM! Extraction APIs updated for new canonical names.The addition of
"css","cssVariants","globalCss", and"rules"correctly reflects the new canonical API identifiers that replace the legacy aliases.examples/react-swc/src/App.css.ts (2)
1-1: LGTM! Import updated to canonical API names.The import statement correctly replaces
globalStyleandstylewithglobalCssandcss, reflecting the removal of legacy aliases from the main package exports.
3-49: LGTM! Function calls consistently updated.All
globalStyleandstylefunction calls have been systematically replaced withglobalCssandcssrespectively, while preserving all CSS content, animations, and styling logic. This properly completes the migration to the canonical API.packages/babel/src/styled.ts (1)
56-60: LGTM! Correctly updated to use the direct export name.The change from
"recipe"to"rules"aligns with the removal of therecipealias and the move to use base function names directly. This ensures the babel plugin works with the updated API surface.packages/css/src/css/index.ts (1)
203-203: LGTM! Tests correctly updated to use base function names.The test cases have been properly updated from
style()tocss(), aligning with the removal of the alias and the move to use base function names directly.Also applies to: 244-244
packages/css/package.json (1)
45-54: LGTM! Properly configured compat module export.The new
"./compat"export subpath correctly provides dual module format support (ESM and CommonJS) with appropriate type declarations, enabling consumers to access the backward-compatible aliases.packages/css/src/index.ts (1)
28-29: LGTM! Export reduction correctly implemented with compat module available.The removal of aliases (
globalStyle,style,styleVariants,recipe) from the main exports is correctly implemented. The backward compatibility concern from previous reviews is now addressed by the newcompat.tsmodule that provides these aliases.packages/css/src/compat.ts (1)
1-49: LGTM! Excellent backward compatibility implementation.This compat module perfectly addresses the backward compatibility concerns raised in previous reviews. It correctly:
- Re-exports vanilla-extract functions that were moved out of main exports
- Provides aliases for renamed functions (
globalCss as globalStyle,css as style,cssVariants as styleVariants)- Re-exports
rules as recipeto maintain the old API- Includes all necessary type exports with appropriate renaming
This ensures consumers relying on the old API can continue to work by importing from
@mincho-js/css/compat.
Docstrings generation was requested by @black7375. * #219 (comment) The following files were modified: * `packages/babel/src/styled.ts` * `packages/css/src/css/index.ts` * `packages/css/src/rules/index.ts`
|
Note Generated docstrings for this pull request at #220 |
|
/fast-forward |
|
Triggered from #219 (comment) by @black7375. Trying to fast forward Target branch ( commit e770e4c9d801828b548ee8bf44c6a499ccd8255e (HEAD -> main, origin/main)
Author: alstjr7375 <alstjr7375@daum.net>
Date: Sat Jun 7 03:58:05 2025 +0900
Chore: Seperate package check CIPull request ( commit 90cde801cc0133649869bfed9c2e053aa600f6db (pull_request/ve-compat-entry)
Author: alstjr7375 <alstjr7375@daum.net>
Date: Sat Jul 19 21:37:30 2025 +0900
Chore: Seperate vanilla extract API to `./compat`Fast forwarding $ git push origin 90cde801cc0133649869bfed9c2e053aa600f6db:main
To https://github.com/mincho-js/mincho.git
e770e4c..90cde80 90cde801cc0133649869bfed9c2e053aa600f6db -> main |
Description
Separate API for Vanilla Extract into
/compat.Related Issue
Summary by CodeRabbit
Chores
Refactor
New Features
Additional context
Checklist