DEV Community

Discussion on: Use Bulma and FontAwesome 5 with Nuxt.js

Collapse
 
maduhaime profile image
Marc-Antoine Duhaime

Can we just use font-awesome as CSS with fonts from the packages?

Collapse
 
mtpiercey profile image
Matthew Piercey

That's totally a legitimate way of doing it; you could even load the CSS from a CDN and import it in nuxt.config.js in the css: option if I'm not mistaken. In fact, it's easier in a lot of ways.

The three main reasons I chose to do it the way I did are:

  • For one reason or another, I like to programmatically load in only the icons I need (even though it isn't easier as such).

  • I've got no scientific proof here, but I'm fairly certain using only the SVG icons you need decreases the bundle size by ~20-30KB

  • I already was using several custom fonts in the project, and I didn't feel like adding another one to the mix.