refactor(v2): merge linkify function used in blog and docs and align properties#4402
Merged
Conversation
|
[V1] Deploy preview success Built with commit 01a6fae |
|
Deploy preview for docusaurus-2 ready! Built with commit 01a6fae |
Contributor
Author
|
Lighthouse failed for unknown reason |
Collaborator
|
Thanks, this looks like a nice code dedup refactor that I wanted to do for a while :) I'm going to tweak some minor things before merging |
|
⚡️ Lighthouse report for the changes in this PR:
Lighthouse ran on https://deploy-preview-4402--docusaurus-2.netlify.app/classic/ |
Collaborator
|
Basically what I did was simplify the signature of the replaceMarkdownLink function, remove the generics and return broken links instead of using a callback (will be simpler to test). BTW we have tests in docs and blog, but if you want to add more isolated tests for this newly extracted method that could be useful ;) |
This was referenced Mar 17, 2021
Closed
This was referenced Mar 17, 2021
Merged
Closed
Closed
Closed
Closed
Closed
mrizwanashiq
pushed a commit
to mrizwanashiq/docusaurus
that referenced
this pull request
Jun 25, 2026
…properties (facebook#4402) * refactor(v2): merge linkify function used in blog and docs * refactor(v2): rename docsDirPath and docsDirPathLocalized ad update types * refactor(v2): rename blogPostsBySource and update types * improve replaceMarkdownLinks api Co-authored-by: slorber <lorber.sebastien@gmail.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.

Motivation
This PR is a continuation of work done in #4391 that aligns names of properties,
i'm unsure what is a politic here on changes, that's why i prepared 2 separate PR's for this
Have you read the Contributing Guidelines on pull requests?
yes
Test Plan
there is no change in functionality and all unit test should pass, linking still should work in docs and in blog,
it can be tested by clicking in one of links in docs, eg.
https://deploy-preview-4391--docusaurus-2.netlify.app/classic/docs/contributing#get-involved
Related PRs
#4391