i want get to string in a multiline string that content any specific character and i want get to between two specific staring.
i used this regex and this work but if
Use catch all character class [\s\S] which means space or non space
[\s\S]
var regex = new RegExp("\-{2}Head([\s\S]*)-{2}\/\Head","m"); var content = "--Head \n any Code \n and String --/Head"; var match = regex.exec(content);