Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

styled-jsx-plugin-px2rem

jyootai11MIT0.0.3

Plugin for px to rem support to styled-jsx

readme

styled-jsx-plugin-px2rem

Plugin for px to rem support to styled-jsx

Usage

Install the package first.

npm install --save-dev styled-jsx-plugin-px2rem

Next, add styled-jsx-plugin-px2rem to the styled-jsx's plugins in your babel configuration:

{
  "plugins": [
    [
      "styled-jsx/babel",
      { "plugins": [["styled-jsx-plugin-px2rem", {"remUnit": 75}]]}
    ]
  ]
}

Notes

styled-jsx-plugin-px2rem uses styled-jsx's plugin system which is supported from version 2.

Read more on their repository for further info.

License

MIT