4.5.7
"stylus-loader": "^4.1.1",
install [email protected]
npm run serve
stylus compile successfully
ERROR Failed to compile with 1 errors 10:42:34 PM
error in ./src/App.vue?vue&type=style&index=0&id=7ba5bd90&lang=stylus&scoped=true
Module build failed (from ./node_modules/stylus-loader/dist/cjs.js):
ValidationError: Invalid options object. Stylus Loader has been initialized using an options object that does not match the API schema.
- options has an unknown property 'preferPathResolver'. These properties are valid:
object { stylusOptions?, sourceMap?, webpackImporter?, additionalData? }
Please use stylus-loader@3 at the moment.
I also encountered this problem, using stylus-loader v3 can solve it
I also encountered this problem, using stylus-loader v3 can solve it
确实有效,将stylus-loader的版本降低到3.0.2 能够成功编译
对,我也试过了,用3.0.2版本的stylus-loader就能编译通过。
- "stylus-loader": "^4.2.0",
+ "stylus-loader": "^3.0.2",
This solves it, but I believe we should ensure that v4.x is supported while bundling the app
nice
Thanks for posting the fix!
Thanks for posting the fix!
Most helpful comment
This solves it, but I believe we should ensure that v4.x is supported while bundling the app