Closed shish closed 1 year ago
Looks like fontawesome v6 will include a "download individual icon as svg" feature which will make this a lot easier, but v6 is currently in subscribers-only beta. Once that's available, it should be trivial to have a folder of FA SVGs, included in our CSS as-needed with parcel's data-url:
Looks like including icons as inline SVGs is faster and more efficient, but they render differently and I'm not sure how to make it look nice :( I've added a draft PR with my work so far in case anybody wants to figure out how to fix the remaining issues
It works now \o/
Not fully automated as there's an issue with parcel's out of the box svg
->jsx
converter, but built with a shell script for now
We use ~10 icons from the FontAwesome icon pack - this adds ~150KB to the final bundle size, and results in some glitchiness because the "Enter Room" button on the front screen has an icon on it, which only loads after a second or two.
If those specific icons were added as SVG embedded in CSS, would that be smaller and faster-loading?