Webpack “OTS parsing error” loading fonts

前端 未结 13 1243
[愿得一人]
[愿得一人] 2020-11-28 20:51

My webpack config specifies that fonts should be loaded using url-loader, and when I try to view the page using Chrome I get the following error:



        
13条回答
  •  夕颜
    夕颜 (楼主)
    2020-11-28 21:10

    As of 2018,

    use MiniCssExtractPlugin

    for Webpack(> 4.0) will solve this problem.

    https://github.com/webpack-contrib/mini-css-extract-plugin

    Using extract-text-webpack-plugin in the accepted answer is NOT recommended for Webpack 4.0+.

提交回复
热议问题