Open milindmore22 opened 1 week ago
@milindmore22 Looking at the rules in that doc:
- Every canonical document must have a link tag with rel=amphtml pointing to its matching AMP document in the same language.
- Every AMP document must have a link tag with rel=canonical pointing to its matching canonical desktop document, again, in the same language.
- Every canonical document must have a link tag with rel=alternate and an hreflang attribute for each alternative language version of the canonical document.
- Every AMP document must have a link tag with rel=alternate and an hreflang attribute for each alternative language version of the AMP document.
We currently are doing (1) and (2). However, for (3) and (4) these are actually additional link
tags, correct? So then do we actually need any filter at all? And what I mentioned to you about needing to remove_action()
in the support topic actually is incorrect, right?
Hello @westonruter yes. that's correct we also don't have to add hreflang
attribute if there are rel=alternate
are added.
<link rel="alternate" href="https://amp.dev/static/samples/internationalization/alternate/index.mobile.html" />
<link rel="alternate" hreflang="en" href="https://amp.dev/static/samples/internationalization/alternate/" />
<link rel="alternate" hreflang="fr" href="https://amp.dev/static/samples/internationalization/alternate/fr/" />
<link rel="alternate" hreflang="ja" href="https://amp.dev/static/samples/internationalization/alternate/ja/" />```
Feature Description
AMP currently does not support the
hreflang
attribute on<link>
tags with the attribute. This allows users to add internationalization to AMP pages to effectively and target specific language or regional audiences.I will suggest adding a filter which will allow programs and users to customize the attribute as per thier requirements.
ref: https://amp.dev/documentation/examples/websites/guides/internationalization/
Acceptance Criteria
No response
Implementation Brief
No response
QA Testing Instructions
No response
Demo
No response
Changelog Entry
No response