Replies: 6 comments 4 replies
-
The |
Beta Was this translation helpful? Give feedback.
-
@nmn Due to health issues I've only been able to pick this up now. Within the package (@acme/button) that contains the stylex style:
Outputs:
As shown here, none of the styles are applied: Also this is the layout.css The use case that I require to start using stylex. Is for a UI component library that is installed via npmjs. Is there anything I can do to help this along? Many thanks! |
Beta Was this translation helpful? Give feedback.
-
So I came across material-ui's new css-in-js and came across this: That's exactly my use case. Good to hear! If you can make some examples (with turborepo), I'd be keen to see them. As I'm having difficultly achieving the same result! Thanks! |
Beta Was this translation helpful? Give feedback.
-
This morning, I was able to take the non-working stylex poc and test out pigment-css. Got it working. So my use case is fulfilled with either griffel and pigment-css. But stylex is seems to be my preferred option. 🤔 |
Beta Was this translation helpful? Give feedback.
-
Somewhat works now, but "use client" needs to be utilised otherwise no styles are bundled in the main css file. Also, when build is run. No styles are bundled in the main css file. Getting there:
The cli looks interesting, will wait for that to mature a little until I try it. 😄 Eventually I'm sure this will all be sorted 🚀 |
Beta Was this translation helpful? Give feedback.
-
I'm trying this with a simple monorepo Vite react app template, and I have the same issue. The vite lib built react component compiles successfully and has a stylex.css file generated but its styles aren't displayed when consumed. Which seems like the opposite off what was said in the following discussion? If I'm reading this right the parent app should consume and compile the child react component and have one stylex.css file generated with all the styles and be consumed correctly? In my case the built package has no in built styles, and it doesn't get compiled by the parent to display styles either. So in either situation this seems wrong. |
Beta Was this translation helpful? Give feedback.
-
Describe the issue
Using turborepo and components within the packages folder.
If a component has the following entry:
StyleX works fine and styles are applied for the component. However it does not scale. My use case is to build the component for installation via npmjs.
The entry for a package to be compiled:
However no styles are applied.
Expected behavior
For styleX to apply styles for compiled packages imported via npmjs
Steps to reproduce
I have a repo to highlight this issue:
Test case
No response
Additional comments
I'm not sure if this has already been covered. Feel free to link an existing issue.
Many thanks!
Beta Was this translation helpful? Give feedback.
All reactions