Having the following example:
var s = '#hello \n##1234 \n #hello2';
var splits = s.split(/#[^##]/);
produces: ["", "ello ↵#", "234 ↵ ", "ello2"]
But want it to produce: ["hello ↵##1234 ↵ ", "hello2"]
How to match single occurrence of character (#) but NOT if its occurring multiple times, and also not the last occurrence of the multiple occurred one.
[^##] == [^#]