Problem/Motivation
I noticed a potential issue re: hreflang tags and Content Translation module: If the URL represents a translated entity and also has a query string, Content Translation module will add hreflang tags without the query string. Hreflang module, however, will add the query string onto each hreflang tag. As a result there will be two sets of hreflang tags in the page, one generated by Content Translation module without the query string, and one generated by Hreflang module with the query string.
Steps to reproduce
Enable Language, Content Translation module and Hreflang modules, add a language, translate a node (e.g. node/1), and visit e.g. node/1?foo=bar
Proposed resolution
This issue could be worked around in Hreflang module if necessary. It could also be resolved in core, see #3226887: Hreflang on non-canonical content pages
Comments
Comment #2
mfbThis is now somewhat mitigated by #2995378: Defer to core content_translation handling of hreflang tags for content entities - if you enable the new setting then there is no conflict with Content Translation module. However, there is still the problem of Content Translation's hreflang tags being invalid when there are query arguments, and the cacheability issue where Content Translation's hreflang tags are shared across requests with different sets of query arguments and without query arguments.
So it seems like a good idea for #3226887: Hreflang on non-canonical content pages to eventually be addressed - e.g. the link HTML tags could use lazy builder placeholders?