I know that a lot of people have posted a similar question but with the g
flag, none of the "hacks" seem to work for me properly (meaning they don't work most of the time). Yes I want the g
flag The regex I've made is:
\~\![A-Za-z]+\ start(?:(?:(?:\(|,)\ ?[\w]+)*?\))\:\{([\S\s]+?)(?:(?<!\\)\}\:end)
This works fine when negative look-behind is supported. But when I do it in JavaScript. It doesn't support negative look behind. Here's the part where the problem lies:
(?:(?<!\\)\}\:end)
\}:end <- Not this
}:end <- This
foo}:end <- This
I've tried: