jsonld: add name to FAQPage + Answer (fixes remaining GSC Item:N/A) - #1396
Merged
Conversation
…des) TechArticle.name was fixed but GSC keeps flagging Item:N/A on the same URLs because it validates the WHOLE @graph, and 2 more nodes lack name: - FAQPage (top-level, inherits name from CreativeWork) - Answer (nested in each Question, same inheritance) Both were missing across all bench pages + answer pages + compare pages. Adds: - buildFaqPageJsonLd gains optional pageName arg (default fallback 'Frequently asked questions') - Answer.name = the question text (semantically: this is the answer TO this question) - Callers on bench/answer/compare pages pass a page-specific name - Inline compare-page FAQ block mirrors the shared builder Same one-liner fix pattern as PR #1257 (TechArticle.name) but on FAQPage + Answer.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Root cause
TechArticle.name was fixed (PR #1257 + restored via #1392). But GSC still complains "Item: N/A" on 5+ bench pages because it validates the WHOLE @graph, not just TechArticle. Exhaustive scan revealed:
Both inherit `name` from CreativeWork per schema.org, and Google's Rich Results validator treats it as required.
Fix
Post-merge
Cherry-pick to main + `vercel --prod`. Then click "Validate fix" in GSC on the 5 flagged URLs. This should be the actual last blocker.