Like between, but also returns the source string without the start/end match and what's between.
const [src,between] = betweenChomp('hello [there] friend', '[', ']');// src: 'hello friend'// between: 'there' Copy
const [src,between] = betweenChomp('hello [there] friend', '[', ']');// src: 'hello friend'// between: 'there'
Optional
Like between, but also returns the source string without the start/end match and what's between.