ifiokjr / gatsby-plugin-next-seo

Gatsby Plugin Next SEO is a plug in that makes managing your SEO easier in Gatsby projects.
MIT License
196 stars 20 forks source link

`lang` attribute #14

Closed just214 closed 4 years ago

just214 commented 4 years ago

Thanks for this plugin, it's great. I don't see a prop for the lang attribute, which is resulting in a Lighthouse audit failure. Am I missing something or is this something you would consider adding if not? Thanks!

ifiokjr commented 4 years ago

Thanks for raising this. This is now added by bd0add9.

Add the language prop to your GatsbySeo component once the release is made available.

just214 commented 4 years ago

Great thanks for the quick response!

jayjayzheng commented 4 years ago

from what I tested, this "language" prop is not working on current version. it's not being added to at all.

any clue if this is taken out by any chance?

ifiokjr commented 4 years ago

Perhaps open a new issue?

DevanB commented 4 years ago

Can confirm that the language prop is not being set as lang (or as anything).

This issue specifically targets the addition, and is so new that I'm wondering what the value of opening a new issue is...if the original implementation was flawed (it was never confirmed to be working by anyone after it was added in bd0add9).

jayjayzheng commented 4 years ago

not "language" and not "lang".

I have to use <Helmet/> separately.

<Helmet htmlAttributes={{ lang, }} />

DevanB commented 4 years ago

Same here. Based on the source, language should be setting the HTML lang value, and it isn’t.

ifiokjr commented 4 years ago

Okay, I'll reopen. I'd be happy for someone else to take a look as I probably won't be able to for a few days.

walker-tx commented 4 years ago

@ifiokjr Could it be that the GatsbySeo component doesn't destructure the language prop and pass it to BaseSeo? I would PR but I honestly have no idea how to test gatsby plugins without installing them via yarn/npm.

github-actions[bot] commented 4 years ago

:tada: This issue has been resolved in version 1.6.1 :tada:

The release is available on:

Your semantic-release bot :package::rocket: