Vue配置px2rem时报错To install them, you can run: npm install --save !!vue-style-loader!css-loader?

出现以下报错是因为没有安装px2rem-loader

* !!vue-style-loader!css-loader?{"sourceMap":true}!../node_modules/vue-loader/lib/style-compiler/index?{"vue":true,"id":"data-v-7ba5bd90","scoped":false,"hasInlineConfig":false}!px2rem-loader?{"remUnit":75}!../node_modules/vue-loader/lib/selector?type=styles&index=0!./App.vue in ./src/App.vue
* !!vue-style-loader!css-loader?{"sourceMap":true,"localIdentName":"[hash:base64]_0","importLoaders":true,"modules":true}!../../../node_modules/vue-loader/lib/style-compiler/index?{"vue":true,"id":"data-v-0c57a6db","scoped":false,"hasInlineConfig":false}!px2rem-loader?{"remUnit":75}!sass-loader?{"sourceMap":true}!../../../node_modules/vue-loader/lib/selector?type=styles&index=0!./Home.vue in ./src/pages/home/Home.vue

To install them, you can run: npm install --save !!vue-style-loader!css-loader?{"sourceMap":true}!../node_modules/vue-loader/lib/style-compiler/index?{"vue":true,"id":"data-v-7ba5bd90","scoped":false,"hasInlineConfig":false}!px2rem-loader?{"remUnit":75}!../node_modules/vue-loader/lib/selector?type=styles&index=0!./App.vue !!vue-style-loader!css-loader?{"sourceMap":true,"localIdentName":"[hash:base64]_0","importLoaders":true,"modules":true}!../../../node_modules/vue-loader/lib/style-compiler/index?{"vue":true,"id":"data-v-0c57a6db","scoped":false,"hasInlineConfig":false}!px2rem-loader?{"remUnit":75}!sass-loader?{"sourceMap":true}!../../../node_modules/vue-loader/lib/selector?type=styles&index=0!./Home.vue

安装px2rem

npm install px2rem-loader --save-dev

 

你可能感兴趣的:(vue)