I have written the following code. But it is removing only not
var docDesc = docDescription.replace(/(&nb
Try this
var text = docDescription.replace(/(?: |)/g,'');