diff --git a/lodash/lodash-tests.ts b/lodash/lodash-tests.ts index 3afc49041b..c1b4d3bd5d 100644 --- a/lodash/lodash-tests.ts +++ b/lodash/lodash-tests.ts @@ -3904,8 +3904,20 @@ module TestRepeat { } // _.snakeCase -result = _.snakeCase('Foo Bar'); -result = _('Foo Bar').snakeCase(); +module TestSnakeCase { + { + let result: string; + + result = _.snakeCase('Foo Bar'); + result = _('Foo Bar').snakeCase(); + } + + { + let result: _.LoDashExplicitWrapper; + + result = _('Foo Bar').chain().snakeCase(); + } +} // _.startCase module TestStartCase { diff --git a/lodash/lodash.d.ts b/lodash/lodash.d.ts index d143f4e657..b775cd8249 100644 --- a/lodash/lodash.d.ts +++ b/lodash/lodash.d.ts @@ -9440,6 +9440,7 @@ declare module _ { interface LoDashStatic { /** * Converts string to snake case. + * * @param string The string to convert. * @return Returns the snake cased string. */ @@ -9453,6 +9454,13 @@ declare module _ { snakeCase(): string; } + interface LoDashExplicitWrapper { + /** + * @see _.snakeCase + */ + snakeCase(): LoDashExplicitWrapper; + } + //_.startCase interface LoDashStatic { /**