return comment

This commit is contained in:
Justin Greywolf
2023-08-15 11:07:21 -07:00
parent bbaab54ec9
commit 3f327196fd

View File

@@ -188,6 +188,8 @@ export const parseGenericTypes = function (text: string): string {
if (text.split('~').length - 1 >= 2) {
let newCleanedText = cleanedText;
// use a do...while loop instead of replaceAll to detect recursion
// e.g. Array~Array~T~~
do {
cleanedText = newCleanedText;
newCleanedText = cleanedText.replace(/~([^\s:;]+)~/, '<$1>');