i want to match string in javascript, but take only part from matched string.
E.g i have string 'my test string' and use match function to get only 'test':
var text = 'my test string';
var matched = text.match(/(?=my).+(?=string)/g);
iam tried to get it in this way but it will return 'my test'. How can i do this to get only 'test' with regex?