首先是需要安装stylus,建议放到npm依赖里。
然后会报错误:
[vite] Internal server error: [stylus] D:/Blog2/node_modules/stylus/lib/functions/index.styl:133:3
129|
130| // lighten by the given amount
131|
132| lighten(color, amount)
133| adjust(color, 'lightness', amount)
----------^
134|
135| // decrease opacity by amount
136|
TypeError: expected rgba or hsla, but got ident:$textColor
at "i" (D:/Blog2/node_modules/@vuepress-reco/vuepress-plugin-kan-ban-niang/bin/KanBanNiang.vue:39:36)
at ".operation" (D:/Blog2/node_modules/@vuepress-reco/vuepress-plugin-kan-ban-niang/bin/KanBanNiang.vue:34:5)
at ".banniang-container" (D:/Blog2/node_modules/@vuepress-reco/vuepress-plugin-kan-ban-niang/bin/KanBanNiang.vue:19:3)
感觉是stylus的语法错误
在D:\Blog2\node_modules\@vuepress-reco\vuepress-plugin-kan-ban-niang\bin\index.vue的style标签中所有使用lighten这个stylus函数的位置都会报错,我直接注释掉不用lighten之后就可以了。
首先是需要安装stylus,建议放到npm依赖里。 然后会报错误: [vite] Internal server error: [stylus] D:/Blog2/node_modules/stylus/lib/functions/index.styl:133:3 129| 130| // lighten by the given amount 131| 132| lighten(color, amount) 133| adjust(color, 'lightness', amount) ----------^ 134| 135| // decrease opacity by amount 136|
TypeError: expected rgba or hsla, but got ident:$textColor at "i" (D:/Blog2/node_modules/@vuepress-reco/vuepress-plugin-kan-ban-niang/bin/KanBanNiang.vue:39:36) at ".operation" (D:/Blog2/node_modules/@vuepress-reco/vuepress-plugin-kan-ban-niang/bin/KanBanNiang.vue:34:5) at ".banniang-container" (D:/Blog2/node_modules/@vuepress-reco/vuepress-plugin-kan-ban-niang/bin/KanBanNiang.vue:19:3) 感觉是stylus的语法错误 在D:\Blog2\node_modules\@vuepress-reco\vuepress-plugin-kan-ban-niang\bin\index.vue的style标签中所有使用lighten这个stylus函数的位置都会报错,我直接注释掉不用lighten之后就可以了。