RFC: strategies for conversion to styled-components
A. Where the same class was applied to multiple components, what is the best way to share it?
- A string 'mixed in' to each styled component?
-
.extends
? - Something else?
Example: !67 (comment 14804)
B. If a group of styles need to be switched in for different props, is it best to:
- Render a different styled component entirely (albeit one generated with shared css, a la question 1)
- Equivocate inside the styles of a single component with
props => props.option1 ? option1 : option2
Example: !67 (comment 14808)
C. Where a component accepts arbitrary JSX:
- Should it be refactored to not accept arbitrary JSX
- Should styles be passed in with the the JSX
Example: !67 (comment 14803)