samayo / country-json

A simple data of the world by country each in JSON format.
https://data.world/samayo
MIT License
1.07k stars 805 forks source link

Some of the encoded SVGs are enormous. #242

Closed jezmck closed 3 months ago

jezmck commented 1 year ago

e.g. Afghanistan, which could be less than half the size by running it though SVGOMG: https://gist.github.com/jezmck/6f8e7a3c8d8451563c6e1e83bde7bb90 or Andorra which could be a third of the size: https://gist.github.com/jezmck/6f7b2f396abc142081491d6a8f50f6ad

Could you please optimize them?

samayo commented 1 year ago

Thanks for bringing this to my attention. I will work on it in the near future.

samayo commented 3 months ago

i tried but simply can't find the time for this specially since it is not critical

jezmck commented 3 months ago

I guess it's because of the large filesize, but I can't create a PR with my change, nor even push to my own fork, nor create a gist with the updated contents.

It seems the best I can do is give you a NodeJS script which loops through the file and creates a new one.

https://gist.github.com/jezmck/5f3c41f34b191427213d86a35deb4a6e

It can also save SVGs as file so they can easily be checked.