Compression svg file for website optimization

930 Views Asked by At

I use Opencart ecommerce software version OC2. When I measure the Google's pagespeed Insights for my website, I get the following complaint about my journal-icons.svg file which allows me to use certain icons at my site:

Enable compression for the following resources to reduce their transfer size by 110.7KiB (72% reduction).
Compressing /catalog/view/theme/journal2/css/icons/fonts/journal-icons.svg could save 110.7KiB (72% reduction).

According to the provider of my template, this file is needed and can not be compressed. The file is 154 kB.

Are there any workarounds to avoid this complaint? For example filtering this file in order to keep only the code for the icons used and deleting the others?

According to an extract from my htacces file below, I understand that svg files are accessible for compression (but I'm really not a technician in this field):

RewriteCond %{SCRIPT_FILENAME} !-d
RewriteRule ^(\/?((catalog)|(assets)).+)\.js$ assets/script.php?l=4&p=$1&c=604800 [NC,L]
AddType image/svg+xml .svg
AddOutputFilterByType DEFLATE image/svg+xml
AddType application/x-font-woff .woff
AddOutputFilterByType DEFLATE application/x-font-woff

Is there anybody who could help me out or have suggestions?

Regards SabKo

0

There are 0 best solutions below