Uniapp Use vant Weapp icon Module Error [How to Fix]

1. Abnormal information

11:43:21.725 Module build failed (from ./node_modules/postcss-loader/src/index.js):
11:43:21.725 SyntaxError
11:43:21.735 (36:10521) Unclosed bracket
11:43:21.736   34 | 
11:43:21.741   35 | 
11:43:21.742 > 36 | @import '../common/index.css';.van-icon{text-rendering:auto;-webkit-font-smoothing:antialiased;font:normal normal normal 14px/1

 

Solution:

Modify /wxcomponents/vant/icon/index wxss

The following figure in the format (“woff2”) after the url in front of a space, you need to modify two places

Read More: