babel-plugin-linaria-interop
This plugin allows to interpolate Linaria components inside styled-components and Emotion:
;; // Linaria component const Article = { /* … */ }; Article` & > { color: green; }`;
Quick start
Install the plugin first:
npm install --save-dev babel-plugin-linaria-interop
Then add linaria-interop
to your babel configuration before styled-components
:
{ "plugins": [ ["linaria-interop", { "library": "styled-components" }], "styled-components" ]}