Currently i am working on an application that splits a long column into short ones. For that i split the entire text into words, but at the moment my regex splits numbers to
Use lookahead to avoid replacing dot if not followed by space + word char:
sentences = str.replace(/(?=\s*\w)\./g,'.|').replace(/\?/g,'?|').replace(/\!/g,'!|').split("|");
OUTPUT:
["This is a long string with some numbers [125.000,55 and 140.000] and an end. This is another sentence."]