add ref
All checks were successful
Lint and Format Check / lint-and-format (pull_request) Successful in 43s
All checks were successful
Lint and Format Check / lint-and-format (pull_request) Successful in 43s
This commit is contained in:
parent
5b659d9948
commit
b1943ea84d
1 changed files with 1 additions and 0 deletions
|
@ -108,6 +108,7 @@ export const cleanCodeBlock = (text: string) => {
|
||||||
});
|
});
|
||||||
|
|
||||||
// Keep links
|
// Keep links
|
||||||
|
// Reference: https://stackoverflow.com/a/3809435/15436737
|
||||||
text = text.replace(
|
text = text.replace(
|
||||||
/https?:\/\/(www\.)?[-a-zA-Z0-9@:%._+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b[-a-zA-Z0-9()@:%_+.~#?&//=]*/g,
|
/https?:\/\/(www\.)?[-a-zA-Z0-9@:%._+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b[-a-zA-Z0-9()@:%_+.~#?&//=]*/g,
|
||||||
function (url: string) {
|
function (url: string) {
|
||||||
|
|
Loading…
Reference in a new issue