Skip to content
Advertisement

Tag: styled-jsx

How to render custom generated ruleset in styled-jsx

TL;DR How does one insert a variable that contains one or more CSS rules into styled-jsx (using styled-jsx-plugin-sass under the hood)? I have the following JSX style: And contained is a variable that I’m trying to insert into it the mentioned rule: Notes: breakAt is a function that generates a specific media query (breakpoint: string) => (content: string) => string

Advertisement