This article mainly introduces the solution to the error problem when referencing Alibaba font icons in Vue. Interested friends can learn together.
I want to quote Alibaba's iconfont in Vue, but an error occurs. The reason is There is no corresponding loader to process font files.
Solution
1.Introduce css file
import 'font-awesome/css/font-awesome.min.css'
2.Configure
{ test: /\.(eot|svg|ttf|woff|woff2)$/, loader: 'file-loader' }
The above is what I compiled for everyone. I hope it will be helpful to everyone in the future.
Related articles:
How to solve the problem of change events in the VUE listening window
watch monitoring routing changes and watch monitoring objects ( Detailed tutorial)
How to implement changes in watch monitoring objects and corresponding values in vue
The above is the detailed content of How to reference Ali font icon in vue. For more information, please follow other related articles on the PHP Chinese website!