feat(v2): exhaustive BlogPostFrontMatter schema validation#4759
Merged
slorber merged 5 commits intofacebook:masterfrom May 14, 2021
Merged
feat(v2): exhaustive BlogPostFrontMatter schema validation#4759slorber merged 5 commits intofacebook:masterfrom
slorber merged 5 commits intofacebook:masterfrom
Conversation
|
⚡️ Lighthouse report for the changes in this PR:
Lighthouse ran on https://deploy-preview-4759--docusaurus-2.netlify.app/ |
e3f0ae6 to
9db8ac4
Compare
slorber
requested changes
May 11, 2021
Collaborator
slorber
left a comment
There was a problem hiding this comment.
Thanks!
Overall that looks good. Added a few useful changes to do
slorber
reviewed
May 11, 2021
nam-hle
commented
May 12, 2021
Contributor
Author
nam-hle
left a comment
There was a problem hiding this comment.
Thanks for reviewing. I add an annotation for deprecated fields and provide warning messages for them.
Collaborator
|
Thanks, that looks great! Disabling the warnings for now as our own blog posts are still using those frontmatters (content is shared between v1/v2 so we can't update the frontmatter) |
Contributor
Author
|
Thanks. Now I can work on the docs frontmatter smoothly :D |
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.
Motivation
From #4591.
What the PR does
I found the after parsing the frontmatter use
gray-matterpackage, thedatefield will be converted to aDate object, not a raw string. But we are treating it as a string. Currently there is no problem about it, but maybe furture.Have you read the Contributing Guidelines on pull requests?
Yes
Test Plan
Unit test.