diff --git a/lodash/lodash-tests.ts b/lodash/lodash-tests.ts index cc2c430bf..212f13a80 100644 --- a/lodash/lodash-tests.ts +++ b/lodash/lodash-tests.ts @@ -5220,8 +5220,20 @@ module TestTrunc { } // _.unescape -result = _.unescape('fred, barney, & pebbles'); -result = _('fred, barney, & pebbles').unescape(); +module TestUnescape { + { + let result: string; + + result = _.unescape('fred, barney, & pebbles'); + result = _('fred, barney, & pebbles').unescape(); + } + + { + let result: _.LoDashExplicitWrapper; + + result = _('fred, barney, & pebbles').chain().unescape(); + } +} // _.words module TestWords { diff --git a/lodash/lodash.d.ts b/lodash/lodash.d.ts index 1870a4d47..93221205a 100644 --- a/lodash/lodash.d.ts +++ b/lodash/lodash.d.ts @@ -10812,6 +10812,7 @@ declare module _ { /** * The inverse of _.escape; this method converts the HTML entities &, <, >, ", ', and ` * in string to their corresponding characters. + * * @param string The string to unescape. * @return Returns the unescaped string. */ @@ -10825,6 +10826,13 @@ declare module _ { unescape(): string; } + interface LoDashExplicitWrapper { + /** + * @see _.unescape + */ + unescape(): LoDashExplicitWrapper; + } + //_.words interface LoDashStatic { /**