Convert any CSS-string to Styled-format object or CSS-in-JS object with CSS-declarations as strings.
yarn add @j-kallunki/css-in-to-js
OR
npm install --save @j-kallunki/css-in-to-js
import { cssToJs } from '@j-kallunki/css-in-to-js';
const cssObject = cssToJs(cssString);
If you wan't to get CSS-declarations in CSS-string format use:
const cssObject = cssToJs(cssString, { cssToString: true })
Minify CSS-string
Uses PostCSS for parsing the CSS.