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

OpenGraph image doesn't work on linkedin because the meta tag is missing a name attribute #1311

Open
voiys opened this issue Oct 31, 2023 · 1 comment

Comments

@voiys
Copy link

voiys commented Oct 31, 2023

Describe the bug
My OpenGraph image is not showing up on linkedin

Reproduction
I use the openGraph property as usual

Expected behavior
There should be an image embedded when I share the link

Additional context
This is what it says in their debugged, I've managed to get around it by adding a <Head /> with the meta tag that has the name attribute
image

@voiys
Copy link
Author

voiys commented Oct 31, 2023

I'd add this to a PR but it doesn't let me push the branch

inside src/meta/buildTags.tsx:

if (mediaType === 'image') {
      tags.push(
        <meta
          key={`og:${mediaType}:0${index}`}
          name={mediaType}
          property={`og:${mediaType}`}
          content={medium.url}
        />,
      );
    } else {
      tags.push(
        <meta
          key={`og:${mediaType}:0${index}`}
          property={`og:${mediaType}`}
          content={medium.url}
        />,
      );
    }

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