My String:
var string = 'Testing(10)';
I want to remove '(10)' form string with usign jquery
CodePudding user response:
You actually don't need jquery for this:
You can do it like this: string.replace(/ *\([^)]*\)*/g, "")
Demo
var string = 'Testing(10)';
console.log(string.replace(/ *\([^)]*\)*/g, ""))