Category "styled-components"

Styled Components / React - Style on Fragment element

I have a question with StyledComponents, it's possible to create a style using a React.Fragment or any other existing component? I use this example (The intent

How to pass props to a styled component in emotion? Using TypeScript

I am using styled by emotion at: import styled from '@emotion/styled' I am trying to pass props to a styled component like the guide mentions: https://emoti

StyledComponents with Typescript and ThemeProvider. What are the right types?

I have problems to get the right types when using StyledComponents with ThemeProvider. I have tried it with this approach: https://github.com/styled-components/

How to select parent components variant in styled components?

In styled-components we can add contextual styles using component selector pattern. But how do we select specific parents variants to contextually style the chi

How do I configure prettier to format tsx file which use styled component?

Here is what is expected after formatting my file : export const StyledDiv = styled.div<StyledDivProps>` width: 56px; height: 30px; `; And this i

Approach to creating variants with styled components

What is the best way to create variants using styled components? Heres what i am currently doing. const ButtonStyle = styled.button` padding:8px 20px; bor

Flash Of Unstyled Text (FOUT) on reload using next.js and styled components

I'm using global style from styled components with next.js and every time I reload my page I can see the font flickering. I have my font files in public/fon

Getting "Types of property 'accessibilityRole' are incompatible" error

Am getting typescript error when i extend th TextProps from react-native and pass it to the Text component created by styled-component Overload 1 of 2, '(prop