How does the “Insert Icon” feature work behind the scenes?

I’ve just stumbled into the Insert Icon feature. Pretty neat.

How does this work when I publish? I get that Sparkle is using Font Awesome which has 7000+ icons. If I use an icon, will the entire font need to be downloaded by a site visitor? will Sparkle upload the entire font to my website?

That’s one of the reasons not to use icons via their icon font, you’ll find many articles on the web about not using them.

Sparkle produces the equivalent inlined SVG, overcoming most/all issues with the direct icon font use.

2 Likes

This is really cool, thanks. Was this introduced in version 4?

Yes and I now realize it didn’t even get a mention in the introduction blog post, though it’s mentioned in the what’s new.

Also something that’s upcoming in a future update (we already developed it so it will come) is one of the contention points for icon fonts, which is accessibility. A future Sparkle will automatically add the description to the SVG image, helping with screen readers and similar technologies.

5 Likes

Thank you Duncan.

This is what I love about Sparkle. Sometimes, users (including myself) complain about a feature that is not there yet. But the ones that are present are so incredibly well thought out.

Best wishes from California.

2 Likes