-
-
Notifications
You must be signed in to change notification settings - Fork 32
How to add a new font awesome icon
Florence Berbey edited this page Jan 4, 2024
·
2 revisions
In order to optimize distribution files sizes, only used font-awesome icons are included in the project.
If you need to use a new icon, please follow this steps :
- identify your icon name, and icon category (solid or regular). Let's say it's
far fa-terrible-icon
- open
/src/js/vue-plugins/font-awesome-config.js
- in relevant import block (regular or solid), add
faTerribleIcon
- please keep alphabetical order
- and if your icon is
regular
, rename it :faTerribleIcon as faTerribleIconRegular
- in
library.add
block, addfaTerribleIconRegular
- that's all, enjoy :
<fa-icon :icon="['far', 'terrible-icon']"></fa-icon>
Oh, and a small reminder : if your remove an icon component from a vue file, please have a rapid check if this icon is used in another source. If not, remove it from fa.config.js
.
- 🏠 Home
- 📋 Changelog
- 🛠️ Dev environment
- 🎉 Resolving issues
- 🤖 CI/CD
- 📝 Tech docs
- 🎓 Courses
- 🤓 Admin