-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[xplat] Initial implementation of griffel-to-stylex converter #30754
[xplat] Initial implementation of griffel-to-stylex converter #30754
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not doing a detailed review now, overall the changes look good and it will be good to get them in the branch where we can iterate on them further.
@@ -38,7 +38,9 @@ | |||
"@fluentui/react-theme": "^9.1.17", | |||
"@fluentui/react-utilities": "^9.18.3", | |||
"@griffel/react": "^1.5.14", | |||
"@swc/helpers": "^0.5.1" | |||
"@stylexjs/stylex": "0.5.0-alpha.4", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you are only calling stylex.create from the native side I don't think you need to bring it in directly. I believe you can call it via:
import { css } from 'react-strict-dom';
const styles = css.create(...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually looks like you already saw this below. I think they added TS support to RSD just recently, might be in 0.0.3, so if this is for types you may want to try updating to that build.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll merge it as it is for now and we can look at switching over to the RSD types once we update to 0.0.3
New Behavior
Adds an initial implementation of a converter from griffel to stylex. This will enable existing web styles to be reused on native.