Can you add support for image sitemap?
Opened this issue · 5 comments
Hi,
I like this repo - so far the simpliest (no stupid requirements) with best documentation. Can you add support for image sitemap? Kindly see this:
- https://developers.google.com/search/docs/advanced/sitemaps/image-sitemaps?hl=en - documentation
- https://github.com/dwightwatson/sitemap - example class how is information about images added to it
I'd like to add it but currently have not enough time for it. A pull request is welcome though.
Yes, I see it as pull request too :D
Add images to an existing sitemap, or create a separate sitemap just for your images.
In order to support image sitemap you basically add new sub-lines according this scheme:
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
xmlns:image="http://www.google.com/schemas/sitemap-image/1.1">
<url>
<loc>http://example.com/sample1.html</loc>
<image:image>
<image:loc>http://example.com/image.jpg</image:loc>
</image:image>
<image:image>
<image:loc>http://example.com/photo.jpg</image:loc>
</image:image>
</url>
<url>
<loc>http://example.com/sample2.html</loc>
<image:image>
<image:loc>http://example.com/picture.jpg</image:loc>
</image:image>
</url>
</urlset>
This increases sitemap.xml file-size. So what about "file-limits" in the case of increasing total generating code. This repo counts overall file-size automatically or in potential pull request I need to alter also "file-limits" part?
This repo counts overall file-size automatically or in potential pull request I need to alter also "file-limits" part?
It should count it well but that should be re-checked.