diff --git a/src/helpers/comment-parser.ts b/src/helpers/comment-parser.ts index c87f92e..65ec8bc 100644 --- a/src/helpers/comment-parser.ts +++ b/src/helpers/comment-parser.ts @@ -2,7 +2,7 @@ import fm from 'front-matter'; const parseComment = (fileContent: string) => { try { - const allCommentBlocks = fileContent.match(/\/\*[\s\S]*?\*\/|([^:]|^)\/\/.*$/g); + const allCommentBlocks = fileContent.match(/\/*[\s\S]*\/.*/g); const vuepressBlock = allCommentBlocks?.filter((block: string) => { return block.split('\n').filter(line => line.indexOf('@vuepress') >= 0).length; })[0];