Skip to content

Add Support for Both Image URLs and ImageObject in Article Structured Data #1496

Open
@MarkAlexanderDev

Description

@MarkAlexanderDev

Is your feature request related to a problem? Please describe.
The next-seo package currently only supports passing image URLs for the images field in Article structured data. However, Google also allows using ImageObject for better flexibility (e.g., including caption) alongside image URLs (https://developers.google.com/search/docs/appearance/structured-data/article#article-types). The lack of support for ImageObject limits compliance with Google's guidelines.

Describe the solution you'd like
Enhance the next-seo package to support both image URLs and ImageObject in the images field, giving developers more flexibility to define additional image properties while maintaining backward compatibility.

Describe alternatives you've considered
Manually injecting structured data to include ImageObject, but this reduces the benefits of using next-seo for streamlined SEO management.

Additional context
Google’s documentation supports both ImageObject and URLs. Adding this feature would improve compliance and SEO performance without breaking existing functionality.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions