I like cleanesss of object-style
const Button = styled.button(
{
color: 'darkorchid'
},
props => ({
fontSize: props.fontSize
})
)
however template(?) style seems to be the main interface that supports more features than object style
const Button = styled.button`
color: hotpink;
`
Is css-string (template) style prefered (or more featured or supported) over object-style in StyledComponent or Emotion.js ?
- Edit
For one difference I know I don't think it's possible to do this with object style
const dynamicStyle = props =>
css`
color: ${props.color};
`
const Container = styled.div`
${dynamicStyle};
`