Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I would like to specify a third attribute within the spear-seo tag, such as specifying hlang for the link-alternate. #175

Open
pandaulait opened this issue Aug 4, 2023 · 0 comments

Comments

@pandaulait
Copy link

pandaulait commented Aug 4, 2023

Is your feature request related to a problem? Please describe.

Describe the solution you'd like

I want to specify alternate in [alias].html like <link rel="alternate" hreflang="en" href="https://example.com/en/blog/content_alias.html" />, but I cannot specify the third attribute with spear -seo does not allow me to specify the third attribute.

<spear-seo
  link-alternate="[https://spearly.com/en/blog/{%=](https://spearly.com/en/blog/%7B%=) article_category %}/{%= article_#alias %}.html"
></spear-seo>

I've heard that cannonical is the least of the problems, but Google's best practice says that alternate should be set, so please consider this as well!

Generated
<link rel="alternate" href="https://spearly.com/en/blog/contents/post-9.html">

What we would like to be able to generate
<link rel="alternate" hreflang="en" href="https://spearly.com/en/blog/features/post-1234.html" />

<link rel="alternate" hreflang="en" href="https://example.com/en/blog/content_alias.html" />のように[alias].html内でalternateを指定したいが、spear-seoだと3つ目の属性を指定できない。

<spear-seo
  link-alternate="[https://spearly.com/en/blog/{%=](https://spearly.com/en/blog/%7B%=) article_category %}/{%= article_#alias %}.html"
></spear-seo>

cannonicalがあれば最低限問題はないらしいのですが、Googleのベストプラクティス的にはalternateを設定するべきらしいので検討もお願いしたいです

生成されたもの
<link rel="alternate" href="https://spearly.com/en/blog/contents/post-9.html">

生成できてほしいもの
<link rel="alternate" hreflang="en" href="https://spearly.com/en/blog/features/post-1234.html" />

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant