on master help sign in
Use standard /regexp/ syntax
dca72d2Liam Cooke
scripts/wiki.js+1−1
@@ -56,7 +56,7 @@ const Wiki = sites => {
56 }
56 }
57
57
58 const formatLinks = text => text.replace(
58 const formatLinks = text => text.replace(
59− new RegExp('\\b((https?|dat)://[^"\\s]+)', 'g'),
59+ /\b((https?|dat):\/\/[^"\s]+)/g,
60 '<a href="$1" target="_blank" rel="noopener noreferrer">$1</a>'
60 '<a href="$1" target="_blank" rel="noopener noreferrer">$1</a>'
61 )
61 )
62
62