Writing an inline style in js,
const styles = {
background: 'blue',
color: 'white'
}
and using it in the JSX as below
<div style={styles}> I am a div </div>
Writing the styles using 'styled components',
const Div= styled.div`
background: 'blue',
color: 'white'
`
and using it like,
<Div> I am a Div </Div>
Here what is the difference in using a css-in-js library and using the inline styles.