šØāš« Co-Founder of This is Learning, Organizer of AarhusJS
āļø Writer, Speaker, FOSS Maintainer š Author
š Microsoft MVP š GitHub Star
š Nx Champion š¦ø Angular Hero of Education
Hey Lars! I haven't got much experience in either, so I can't comment. That being said, I'm super interested in the whole CSS in JS space with CSS Modules/Styled components and other solutions as a way to manage CSS with JS frontend frameworks. If you have any resources worth reading, please share!
šØāš« Co-Founder of This is Learning, Organizer of AarhusJS
āļø Writer, Speaker, FOSS Maintainer š Author
š Microsoft MVP š GitHub Star
š Nx Champion š¦ø Angular Hero of Education
Angular can use either shadow DOM or use what they call emulated view encapsulation which similar to CSS modules assigns unique selectors to each class used in a component. However, the component uses a regular stylesheet and applies regular classes to the HTML elements, the framework does the wiring up.
šØāš« Co-Founder of This is Learning, Organizer of AarhusJS
āļø Writer, Speaker, FOSS Maintainer š Author
š Microsoft MVP š GitHub Star
š Nx Champion š¦ø Angular Hero of Education
What do you think about CSS Modules and shadow styles for web components?
Hey Lars! I haven't got much experience in either, so I can't comment. That being said, I'm super interested in the whole CSS in JS space with CSS Modules/Styled components and other solutions as a way to manage CSS with JS frontend frameworks. If you have any resources worth reading, please share!
I only tried CSS Modules based on this small React sample: create-react-app.dev/docs/adding-a....
Angular can use either shadow DOM or use what they call emulated view encapsulation which similar to CSS modules assigns unique selectors to each class used in a component. However, the component uses a regular stylesheet and applies regular classes to the HTML elements, the framework does the wiring up.
Interesting. Thanks Lars. Iām going to give CSS modules a shot š
I absolutely love them when combined with React.