See, the double quotes stayed, but everything else is broken. Having a bulletproof regex is a real pain. If you want to improve it, you have to modify this var myRegexp = /[^\s"]+|"([^"]*)"/gi;.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
What about double quotes enclosed within single quotes, echo 'And he said: "My name is!" ${name}'. It's a contrived example but you get the gist.
For that you would get.
See, the double quotes stayed, but everything else is broken. Having a bulletproof regex is a real pain. If you want to improve it, you have to modify this
var myRegexp = /[^\s"]+|"([^"]*)"/gi;
.