Fontawesome 6

3 posts by 3 authors in: Forums > CMS Builder
Last Post: June 26   (RSS)

By KennyH - June 9

FontAwesome 6 is coming out soon, but one new feature they have released now is Kits. Instead of using a CDN or downloading all fonts, you can create a Kit for each project. To use the kit, it's just one line of script reference code to put in your head. From that point, I always have the latest icons available for use without having to upgrade.

In CMSB, I deleted from the lib/menus/header.php file (line 37-38):

<link href="<?php echo CMS_ASSETS_URL ?>/3rdParty/font-awesome/css/all.min.css" rel="stylesheet">
<link href="<?php echo CMS_ASSETS_URL ?>/3rdParty/font-awesome/css/v4-shims.min.css" rel="stylesheet">

And replaced it with the same Kit code as referenced in my main CSS file for the website

<script src="https://kit.fontawesome.com/xxxxxxxxxx.js" crossorigin="anonymous"></script>

Everything works great so far. I am hoping that future releases could implement using a Kit instead of having to upgrade the icon packages each time you want access to the latest icons. 

Am I missing anything else with using the kit instead of hosting the files myself?

Kenny H

By daniel - June 11

Hi Kenny,

Thanks for bringing this to our attention! We'll have to look into the implementation and do some testing, but it would certainly be a lot easier to be able to update the icons being loaded to the CMS dynamically rather than having to replace files each time. 

Cheers,

Daniel
PHP Programmer
interactivetools.com