songsiqi / px2rem-postcss

Postcss version of px2rem.
270 stars 49 forks source link

postcss-px2rem破坏了sourceMap的源文件名称 #22

Open rouberg opened 6 years ago

rouberg commented 6 years ago

vue项目。当开启CSS sourceMap时,没有使用postcss-px2rem时,chrome中查看Hello.vue的样式,样式的源的名称会显示为:Hello.vue? [sm]:18 这样,但是在postcss.config.js里配置postcss-px2rem后,px转换成rem是可以,但是样式的源的名称会显示为这样: <input css 10>:1

postcss.config.js配置如下:

module.exports = {
  plugins: {
    'postcss-px2rem': {
      remUnit: 14
    }
  }
}

不知道这是不是在设计之中。以及,可以优化么。