mirror of
https://github.com/lipis/flag-icons.git
synced 2026-04-26 17:35:54 +03:00
[GH-ISSUE #63] Optimize SVGs using SVGO #38
Labels
No labels
3rd-party
3rd-party
bug
code
documentation
enhancement
fixed-in-master
flag-request
help needed
missing-flag
missing-flag
pull-request
wrong-flag
wrong-flag
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/flag-icons#38
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @flekschas on GitHub (Apr 22, 2015).
Original GitHub issue: https://github.com/lipis/flag-icons/issues/63
I would recommend optimizing SVGs using SVGO.
I've done this for all 4x3 SVGs and saved quite a lot of bits:
Average size saved per file: 50.61%
Total size saved: 33.29%
Total file sizes before:
Before: 4690.31 KiB
After: 3128.94 KiB
Average file size:
Before: 18.84 KiB
After: 12.57 KiB
(Strangely I should mention that
aw.svgandms.svggot bigger!)This could me included in the build process using grunt-svgmin, which internally uses SVGO.
@lipis commented on GitHub (Apr 22, 2015):
I've done that in the past.. but unfortunately some of the flags are ruined because of that...
https://github.com/svg/svgo/issues/162
@lipis commented on GitHub (Apr 22, 2015):
Will follow up after I'm back from my vacations.. I'm totally up for SVGO if flags are not breaking.. or at least if we know for sure which ones are breaking.. (like 100% sure)
@flekschas commented on GitHub (Apr 23, 2015):
Sounds great thanks! Maybe I find out how to avoid breaking some flags by disabling certain SVGO plugins.
@lipis commented on GitHub (Apr 23, 2015):
or somehow identifying which flags are breaking is also good for me
@petethepig commented on GitHub (May 25, 2015):
+1
@petethepig commented on GitHub (May 25, 2015):
Another possible improvement would be to get rid of duplicates.
us-umpair for example@lipis commented on GitHub (May 26, 2015):
@petethepig lol.. so lets delete the US flag..
@petethepig commented on GitHub (May 30, 2015):
@lipis I'm saying that this:
could potentially look like this:
Thus, if you have both flags (us and um) on one page you would only have to download one image.
@lipis commented on GitHub (May 30, 2015):
@petethepig This repo is used not only via CSS and this is a very small optimisation that I don't see any reason to modify..
@lipis commented on GitHub (Dec 26, 2015):
Many flags were optmized.. and from now on it will happen on per flag basis..