We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ef15a97 commit 55b3bbdCopy full SHA for 55b3bbd
src/utils/getProcessedText.js
@@ -9,8 +9,8 @@ export const getProcessedText = (text) => {
9
}
10
11
// Regex to match URLs that are NOT already in markdown or HTML link format
12
- // This looks for URLs that are not preceded by ]( or href=" and not followed by )
13
- const urlRegex = /(?<!\]\(|href=["'])https?:\/\/[^\s\[\]()]+(?![)\]])/gi;
+ // This looks for URLs that are not preceded by ]( or href=" or [ and not followed by ) or ]
+ const urlRegex = /(?<!\]\(|href=["']|\[)https?:\/\/[^\s\[\]()]+(?![)\]])/gi;
14
15
// Replace bare URLs with markdown links
16
const processedText = text.replace(urlRegex, (url) => {
0 commit comments