Just have a random dumb question, why is that my below regex is not working ?
var item = "&item";
item.replace('/(&\w+)/g' , 'yolo');
I still don't see the contents of item being replaced with 'yolo'.
Why is my regex not working
Moderator: General Moderators
Re: Why is my regex not working
got it '/(&\w+)/g' should be /(&\w+)/g