I want to filter out text which is not inside the quotation marks.
This is my code example
var string = "text here should be ignored 'text here matters' ignore this 'this matters!'";
var matches = string.match(/'(.*)'/);
console.log(matches);
Current result
[
"'text here matters' ignore this 'this matters!'",
"text here matters' ignore this 'this matters!"
]
Expected result
[
"text here matters",
"this matters!"
]