How to: Use Font Awesome 5 in your Sage theme

That looks like your dev build. How big is it when you build it for production?

129kB when built for production. No issues here. Thanks for this.

1 Like

I am using FontAwesome Pro as suggested here, and experiencing an issue with duotone icons.

I manage to import them successfully, but they only show the primary part of the icon, not the secondary, and neither the selectors (e.g. --fa-secondary-opacity) nor the duotone-specific classes (e.g. fa-swap-opacity) do anything.

Does anybody has similar issues or knows what could be going on?

import { library, dom } from '@fortawesome/fontawesome-svg-core';

import { faDna } from '@fortawesome/pro-duotone-svg-icons/faDna';

library.add(
  faDna,
  ...
)

dom.watch();

It does work perfectly with light and solid icons, just not as it should with duotone:

22