Hello! I just started making my first map, so I decided to create a small test map first. When I went to upload it, it said the file was too big (it isn't lying, the file is 4.5 kb when about 2kb is the max. It is literally like 16 rectangles, and the size is less than 100 x 100. What am I doing wrong? Thanks for any help.
That's strange. I don't know either. Rectangle tools normally never cause trouble. Make sure everything is converted into pad. Otherways I would recommend a svg optimizer for you to reduce its size, it worked already great for me.
I deleted everything and set the size to 100 by 100 px (it was mm for some reason before). Just the blank canvas is still 4.5mb. I can create a new one and t will have a low filesize, but i have a lot of work in it already (I only made a copy and changed it down to squares to try and lower the filesize. My original file is still intact.)
Ok, I think I tracked it down. Using the optimizer tool King gave me, I figured out that the xlink namespaces was where all the file size is. What is that and how do i prevent it? (Besides running the script every time)
Those namespaces are added svg tags in the script to link its content. They look like this: <svg> <title> <> . That takes such a great space in the script if with many paths or groups in your file. In Warlight those tags are unnecessarily and better without, rendering them useless.
How to prevent it? Well I'm not an expert but I suspect you probably putted some shapes in your svg with special content that differented from casual shapes. Presumably you're maybe the first one on Warlight who has ever encountered this problem.