I know I'm going to be bashed for this question. I know it is basics and I know it was asked many times, but it seems I'm to dumb to understand examples and I need solution. My problem:
user is sending a string to server. It should be /nick #nick_name I want to match only nick_name, I also want to consider situation, when user is not cooperating and send something like "/nick #nick_name and some trash". I don't need #, I don't need space after. I have a permanent brain fart on this.
I know about #(.*) but this match everything after a # (hash included). I need only one word. The perfect solution would be a lookbehind, to catch everything after #, but it's not working on JS. I really did my homework.