报错:Failed to resolve loader: less-loader You may need to install it
网上:npm install less less-loader --save-dev
无用
尝试:npm install less-loader
巨坑!!!!!!!!!!!!!!!!
ERROR Failed to compile with 1 error 11:35:29 ├F10: PM
┤
error in ./src/components/Login.vue?vue&type=style&index=0&id=ef68022e&lang=less&scoped=true&
Syntax Error: TypeError: this.getOptions is not a function
然后就这样啦
没办法啦
瘫痪啦
原因: less-loader安装的版本过高
解决方案: 1.npm uninstall less-loader
2.npm install less-loader@6.0.0