I have specific word (for example "in") after which I want to replace a space with a no-break space. I used plain replace: from " in " to " in" + String.fromCharCode(160).
However words are not always surrounded by spaces - for eample in this sentence:
This is sample text (in which there are parentheses).
So I need a regex to replace a space after "in" with a no-break space. How can I do this?