cannot load png files with webpack, unexpected character

后端 未结 4 922
梦谈多话
梦谈多话 2021-02-02 07:25

Im trying to reconfigure my webpack, and now i cannot load the css files. i keep my styles in src > styles > main.css

I am getting errors such as

ERROR          


        
4条回答
  •  执笔经年
    2021-02-02 07:51

    You are missing an appropriate loader that would match that png of yours. To fix this, set up either url-loader or file-loader so that it matches your png.

    url-loader has a limit option you may find useful. It allows you to control whether or not it emits dataurls (inline) or paths (uses file-loader and emits files matching to paths).

提交回复
热议问题