var text = 'word otherword';
I want to select words that only matches with 'word'. When i use simply /word/
for regex pattern, then it also selects the 'word' part in 'otherword'. I dont need that word(in this case 'otherword').So how can i only select/match 'word' word using regex?