-
-
Notifications
You must be signed in to change notification settings - Fork 37.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bonfire: Convert HTML Entities #1108
Comments
@destino92 Thanks for reporting. We will be tracking this issue at #1062 |
function convertHTML(str) { return String(str).replace(/&/g, '&').replace(/</g, '<').replace(/>/g, '>').replace(/"/g, '"').replace(/'/g,'''); convertHTML("Shindler's List"); |
Dani_anzali@yahoo.com
|
assert.strictEqual(convert('Dolce & Gabbana'), 'Dolce & Gabbana', 'should escape characters');
assert.strictEqual('<>', '<>', 'should escape characters');
should escape characters: expected '<>' to equal '<>'
assert.strictEqual(convert('abc'), 'abc', 'should handle strings with nothing to escape');
The text was updated successfully, but these errors were encountered: