Javascript String toEscapedString()
toEscapedString()
String.prototype.toEscapedString = function() { var sanitizer = require('sanitizer') var s = this;/*w w w .ja va2s. co m*/ return sanitizer.escape(s); };