feat: 暂时不使用chatgpt-api库,拷贝了部分其代码进行修改

This commit is contained in:
葛胤池 2022-12-17 11:35:59 +08:00
parent b8bd3dfec9
commit d0dcc50764
5 changed files with 1166 additions and 19 deletions

View file

@ -1,9 +0,0 @@
/**
* 判断一段markdown文档中是否包含代码
* @param text
*/
export function codeExists (text = '') {
let regex = /^[\s\S]*\$.*\$[\s\S]*/
return regex.test(text)
}