let test = 'hello world' // 后行断言 let res = test.match(/hello(?=\sworld)/) console.log(res) // 先行断言 res = test.match(/(?<=hello\s)world/) console.log(res)
版权属于:
emer
文章声明:
本文版权内容属于《快乐小窝》转载请标明出处
评论一下?