mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-05 01:17:50 +00:00
Bump to v4.7.0.
This commit is contained in:
14
escape.js
14
escape.js
@@ -13,20 +13,22 @@ define(['./_escapeHtmlChar', './toString'], function(escapeHtmlChar, toString) {
|
||||
*
|
||||
* Though the ">" character is escaped for symmetry, characters like
|
||||
* ">" and "/" don't need escaping in HTML and have no special meaning
|
||||
* unless they're part of a tag or unquoted attribute value.
|
||||
* See [Mathias Bynens's article](https://mathiasbynens.be/notes/ambiguous-ampersands)
|
||||
* unless they're part of a tag or unquoted attribute value. See
|
||||
* [Mathias Bynens's article](https://mathiasbynens.be/notes/ambiguous-ampersands)
|
||||
* (under "semi-related fun fact") for more details.
|
||||
*
|
||||
* Backticks are escaped because in IE < 9, they can break out of
|
||||
* attribute values or HTML comments. See [#59](https://html5sec.org/#59),
|
||||
* [#102](https://html5sec.org/#102), [#108](https://html5sec.org/#108), and
|
||||
* [#133](https://html5sec.org/#133) of the [HTML5 Security Cheatsheet](https://html5sec.org/)
|
||||
* for more details.
|
||||
* [#133](https://html5sec.org/#133) of the
|
||||
* [HTML5 Security Cheatsheet](https://html5sec.org/) for more details.
|
||||
*
|
||||
* When working with HTML you should always [quote attribute values](http://wonko.com/post/html-escaping)
|
||||
* to reduce XSS vectors.
|
||||
* When working with HTML you should always
|
||||
* [quote attribute values](http://wonko.com/post/html-escaping) to reduce
|
||||
* XSS vectors.
|
||||
*
|
||||
* @static
|
||||
* @since 0.1.0
|
||||
* @memberOf _
|
||||
* @category String
|
||||
* @param {string} [string=''] The string to escape.
|
||||
|
||||
Reference in New Issue
Block a user