links markdown support

This commit is contained in:
DeaDvey 2024-11-17 22:23:37 +00:00
parent ab14c76cff
commit 4273b45f39

View File

@ -25,6 +25,8 @@ const encode = (unsafe) => {
// Italics
.replace(/\*(.*?)\*/g,'<i>$1</i>')
//links
.replace(/\[(.*?)\]\((.*?)\)/g,'<a href="$2">$1</a>')
};
// Middleware to parse URL-encoded and JSON bodies