0.0.1 • Published 4 years ago

postcss-rpx2rem-loader v0.0.1

Weekly downloads
4
License
-
Repository
-
Last release
4 years ago

Now you can use rpx in your style sheets.

div {
  height: 20rpx;  
}
div {
  height: 0.20rem;
}

Integrate with Vue CLI

Run npm i px2rpx-loader -D in the root directory of your project.

In package.json

{
  "name": "",
  "version": "",
  // ...
  "postcss": {
    "plugins": {
      "autoprefixer": {},
      "px2rpx-loader": { "fontSize": 100 } // Add root fontsize(default 100)
    }
  }
}