Remplacez le symbole s'il est précédé et suivi d'un caractère de mot js

This Works to find when a word is followed by another chars
string.match(/word([^s]|^)/) 

You can use ([^s]|^) before or after the word.

Cases: 
If the word has other char/word before it the code is:
string.match(/([^s]|^)word/)
If the word has other char/word after it the code is:
string.match(/word([^s]|^)/)
Sergiu The Man