(feature) Add _.lowerCase and _.lowerFirst

This commit is contained in:
DomiR
2016-01-23 14:43:48 +01:00
parent c64f7a35b7
commit dcf0aac8b2
2 changed files with 105 additions and 0 deletions
+32
View File
@@ -8289,6 +8289,38 @@ module TestKebabCase {
}
}
// _.lowerCase
module TestLowerCase {
{
let result: string;
result = _.lowerCase('Foo Bar');
result = _('Foo Bar').lowerCase();
}
{
let result: _.LoDashExplicitWrapper<string>;
result = _('Foo Bar').chain().lowerCase();
}
}
// _.lowerFirst
module TestLowerFirst {
{
let result: string;
result = _.lowerFirst('Foo Bar');
result = _('Foo Bar').lowerFirst();
}
{
let result: _.LoDashExplicitWrapper<string>;
result = _('Foo Bar').chain().lowerFirst();
}
}
// _.pad
module TestPad {
{
+73
View File
@@ -13078,6 +13078,79 @@ declare module _ {
kebabCase(): LoDashExplicitWrapper<string>;
}
//_.lowerCase
interface LoDashStatic {
/**
* Converts `string`, as space separated words, to lower case.
*
* @static
* @memberOf _
* @category String
* @param {string} [string=''] The string to convert.
* @returns {string} Returns the lower cased string.
* @example
*
* _.lowerCase('--Foo-Bar');
* // => 'foo bar'
*
* _.lowerCase('fooBar');
* // => 'foo bar'
*
* _.lowerCase('__FOO_BAR__');
* // => 'foo bar'
*/
lowerCase(string?: string): string;
}
interface LoDashImplicitWrapper<T> {
/**
* @see _.lowerCase
*/
lowerCase(): string;
}
interface LoDashExplicitWrapper<T> {
/**
* @see _.lowerCase
*/
lowerCase(): LoDashExplicitWrapper<string>;
}
//_.lowerFirst
interface LoDashStatic {
/**
* Converts the first character of `string` to lower case.
*
* @static
* @memberOf _
* @category String
* @param {string} [string=''] The string to convert.
* @returns {string} Returns the converted string.
* @example
*
* _.lowerFirst('Fred');
* // => 'fred'
*
* _.lowerFirst('FRED');
* // => 'fRED'
*/
lowerFirst(string?: string): string;
}
interface LoDashImplicitWrapper<T> {
/**
* @see _.lowerFirst
*/
lowerFirst(): string;
}
interface LoDashExplicitWrapper<T> {
/**
* @see _.lowerFirst
*/
lowerFirst(): LoDashExplicitWrapper<string>;
}
//_.pad
interface LoDashStatic {
/**