jameslnewell / styled-components-breakpoint

Utility function for using breakpoints with styled-components 💅.
243 stars 17 forks source link

Formatting css inside the template strings #31

Open guitheengineer opened 3 years ago

guitheengineer commented 3 years ago

Prettier doesn't seems to work with css inside the template string.

As a workaround, seems possible to enable formatting by using the styled-components helper function css

export const SC = styled.div`
  ${breakpoint('lg')`${css`
    height: 100%;
  `}`}
`;

but as you can see, is doesn't look good, any alternatives?