jekyll / jekyll-sitemap

Jekyll plugin to silently generate a sitemaps.org compliant sitemap for your Jekyll site
http://rubygems.org/gems/jekyll-sitemap
MIT License
961 stars 135 forks source link

Allow multilingual sitemap #198

Closed Ryuno-Ki closed 6 years ago

Ryuno-Ki commented 6 years ago

Similiar to #88 I think, there is something to do on this plugin as well.

From what I've read in Google Search Console Help - Use a sitemap to indicate alternate language pages the sitemap.xml template would need to include xmlns:xhtml="http://www.w3.org/1999/xhtml" in <urlset> and render tags like the following as child of <url>:

<xhtml:link rel="alternate" hreflang="de" href="http://www.example.com/deutsch/" />

I can imagine two ways how this could work with a multilang plugin (https://github.com/Anthony-Gaudino/jekyll-multiple-languages-plugin/issues/68 for example).

  1. Offering a hook to add those bits by the other plugin.
  2. Defining a key in _config.yml to read out for this.

I have to think about how to render the concrete routes, too.

Which route would the @jekyll team prefer? I am willing to refresh my Ruby skills to address it :)

Ryuno-Ki commented 6 years ago

Maybe #189 can be adressed here, too.

jekyllbot commented 6 years ago

This issue has been automatically marked as stale because it has not been commented on for at least two months.

The resources of the Jekyll team are limited, and so we are asking for your help.

If this is a bug and you can still reproduce this error on the master branch, please reply with all of the information you have about it in order to keep the issue open.

If this is a feature request, please consider whether it can be accomplished in another way. If it cannot, please elaborate on why it is core to this project and why you feel more than 80% of users would find this beneficial.

This issue will automatically be closed in two months if no further activity occurs. Thank you for all your contributions.

Ryuno-Ki commented 6 years ago

Still relevant. What do you need?

pathawks commented 6 years ago

Is this a duplicate of #88? That issue is still wont-fix for the reasons described there.

Otherwise, I’m not sure how this would be implemented. Jekyll currently has no concept of different pages that have the same content translated into different languages.

Ryuno-Ki commented 6 years ago

Well, partially. As I commented in #88 the description („with the current design”) is too vague. I'd like to understand what makes it so hard in order to see, why it is considered not feasible.

Can you point me to some points in the code so I can dig into it? I've learned a bit of Ruby together with Rails.

pathawks commented 6 years ago

https://github.com/jekyll/jekyll-sitemap/issues/88#issuecomment-164302555

Ryuno-Ki commented 6 years ago

That's still not a link to the exact line of code where you see the issue. This way it is impossible to think about whether a patch would be possible.

pathawks commented 6 years ago

The issue is not a specific line of code, but the fundamental design of that plugin.

If I knew how to fix it I would have fixed it.

Ryuno-Ki commented 6 years ago

Hm, okay. :-/ Thanks for taking the time.