feat(core): siteConfig.headTags API to render extra tags in document head#8151
Merged
Conversation
✅ [V2]
To edit notification comments on pull requests, go to your Netlify site settings. |
⚡️ Lighthouse report for the deploy preview of this PR
|
Contributor
Author
|
Pretty sure build performance test will pass if you rerun it - not sure what happened there. Nothing significant should have changed with this PR - no segfaults received when building on my old local machine 😅 |
slorber
requested changes
Oct 7, 2022
slorber
left a comment
Collaborator
There was a problem hiding this comment.
Thanks, looks like the API I want 👍
config.headTags or config.head, not sure what is best. Not a big deal, we can change later if we want.
I'd rather remove any ref to the WIP monetization API for now and use a simpler example
Also good to have more validation tests
Contributor
Author
|
I think that's the feedback addressed! |
Contributor
Author
|
Does this look okay @slorber ? |
slorber
reviewed
Oct 12, 2022
slorber
approved these changes
Oct 12, 2022
slorber
left a comment
Collaborator
There was a problem hiding this comment.
Thanks
Will do the cleanup and merge 👍
Contributor
Author
|
Awesome! |
johnnyreilly
added a commit
to johnnyreilly/blog.johnnyreilly.com
that referenced
this pull request
Oct 20, 2022
slorber
added a commit
that referenced
this pull request
Oct 28, 2022
…head (#8151) Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
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.
Pre-flight checklist
stylesheetsAPI more generalized #8049) and the maintainers have approved on my working plan.Motivation
This is a follow on of #8077 - motivation copied from there:
I'm trying to add a custom link tag to the header of all the pages on my Docusaurus site. In my case I'm looking to render a web monetization link which looks like this:
It looks like there isn't a way to generically supply global link tags with Docusaurus. At least... until now!
Test Plan
Herewith a screenshot of the new documentation and the rendered link tag:
There's a failing "Build Performance" test - it doesn't seem to be related to the changes in this PR; I'm guessing this is a flaky test. No issues building locally.
Test links
Deploy preview: https://deploy-preview-8151--docusaurus-2.netlify.app/docs/api/docusaurus-config#headTags
Crack open the devtools and you can see the
linktag present and correct. You may well want to replace this link tag with your own!Related issues/PRs
#8077
#8049