tastypie
Version:
Tastypie is a webservice API framework for Node.js based on Django's Tastypie Framework. It provides a convenient, yet powerful and highly customizable, abstraction for creating REST-style interfaces
19 lines (14 loc) • 409 B
JavaScript
var toString = require('../lang/toString');
/**
* Unescapes HTML special chars
*/
function unescapeHtml(str){
str = toString(str)
.replace(/&/g , '&')
.replace(/</g , '<')
.replace(/>/g , '>')
.replace(/�*39;/g , "'")
.replace(/"/g, '"');
return str;
}
module.exports = unescapeHtml;