Skip to content

Improve BlogPosting schema: require fields, add publisher - #878

Merged
poppastring merged 1 commit into
mainfrom
fixing-json-schema
Sep 12, 2026
Merged

poppastring merged 1 commit into
mainfrom
fixing-json-schema

Conversation

@poppastring

Copy link
Copy Markdown
Owner

Improve BlogPosting schema: require fields, add publisher

BlogPostingSchemaTagHelper now requires DatePublished and Canonical to emit schema output, suppressing otherwise. The schema @context uses "https://schema.org". Publisher metadata is supported and emitted as an Organization if present. Tests use a MakePostViewContext helper to set required metadata, and new tests cover publisher emission and output suppression. DasBlogBaseController sets PublisherName, PublisherUrl, and always sets Author in ViewData.

BlogPostingSchemaTagHelper now requires DatePublished and Canonical to emit schema output, suppressing otherwise. The schema @context uses "https://schema.org". Publisher metadata is supported and emitted as an Organization if present. Tests use a MakePostViewContext helper to set required metadata, and new tests cover publisher emission and output suppression. DasBlogBaseController sets PublisherName, PublisherUrl, and always sets Author in ViewData.
@poppastring
poppastring merged commit 3adcfc5 into main Sep 12, 2026
3 checks passed
@poppastring
poppastring deleted the fixing-json-schema branch September 12, 2026 20:02
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

Successfully merging this pull request may close these issues.

1 participant