How to add Fontawesome 5 to Symfony 4 using Webpack Encore

后端 未结 7 1616
鱼传尺愫
鱼传尺愫 2020-12-29 04:34

I want to add Font Awesome 5 to my Symfony 4 project, this is what I did :

  • I added font awesome to my project using yarn : yarn add --dev @fortawesome/f
7条回答
  •  醉酒成梦
    2020-12-29 05:01

    I think I found a solution to your problem, It is not probably the best but a starting point. According to Font Awesome Documentation you should add the all.css to your code. Or the @fontface imports statements there.

    import '~@fortawesome/fontawesome-free/css/all.css';

提交回复
热议问题