The first global introduction:
in main.js
import './assets/iconfont/iconfont.css' //Note that './' must be added or an error will be reported
The second kind of local introduction:
in the component
<style scoped>
@import '../assets/iconfont/iconfont.css';
</style>
Reprinted from https://blog.csdn.net/m0_38069630/article/details/76512078