DefaultSeo og:title and og:description only overridden by NextSeo when openGraph config provided
See original GitHub issueHi! First off, thank you so much for this library!
I noticed some unexpected behavior (not sure if it’s a bug or intended) when using DefaultSeo and NextSeo. The DefaultSeo og:title and og:description meta tags are not overridden by NextSeo’s title and description configurations unless an openGraph configuration object is provided to NextSeo. I believe this is due to https://github.com/garmeeh/next-seo/blob/master/src/meta/buildTags.tsx#L152 evaluating as falsy in NextSeo so the og:* meta tags are never updated.
I’ve reproduced this behavior in the sandbox below where the / page does not successfully overwrite the meta tags while the /about page does.
https://codesandbox.io/s/serene-mcnulty-ofcu3
Let me know if anything else would be useful to debug!
Issue Analytics
- State:
- Created 3 years ago
- Reactions:6
- Comments:6 (2 by maintainers)

Top Related StackOverflow Question
It’s not yet fixed. Temporary workaround is to just provide an empty object to the
openGraphproperty:This will overwrite/update the
og:titleandog:description, becauseopenGraphwill evaluate totruthyinbuildTags.tsx: https://github.com/garmeeh/next-seo/blob/420eb12ff7c6d2e15412d3bd09a0dca27863084f/src/meta/buildTags.tsx#L188I’m still experiencing this. If an OpenGraph image array is defined in DefaultSEO, it overrides individual pages’ default images. Any updates?