我想在.vue文件的<script>中是用stylus
let stylus = require('stylus')
console.log(stylus)
但是失败了。
This dependency was not found:
* fs in ./~/.0.54.5@stylus/lib/utils.js, ./~/.0.54.5@stylus/lib/middleware.js and 12 others
To install it, you can run: npm install --save fs
This relative module was not found:
* ./lib-cov/stylus in ./~/.0.54.5@stylus/index.js
我新建了个test.js文件,在里面引用却没问题。
我试过在webpack.base.conf.js 中设置这个:
{
test: /\.styl$/,
loader: 'style-loader!css-loader!stylus-loader'
}
没用。
有人有踩过这个坑或者任何想法吗?
感谢
蛊毒传说
相关分类