@types/lodash 4.14.100 → 4.14.104

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (327) hide show
  1. lodash/README.md +2 -2
  2. lodash/common/array.d.ts +3845 -0
  3. lodash/common/collection.d.ts +3091 -0
  4. lodash/common/common.d.ts +3 -3
  5. lodash/{date/now.d.ts → common/date.d.ts} +3 -1
  6. lodash/common/function.d.ts +1367 -0
  7. lodash/common/lang.d.ts +1937 -0
  8. lodash/common/math.d.ts +536 -0
  9. lodash/{number/random.d.ts → common/number.d.ts} +98 -1
  10. lodash/common/object.d.ts +3653 -0
  11. lodash/common/seq.d.ts +198 -0
  12. lodash/common/string.d.ts +1059 -0
  13. lodash/common/util.d.ts +1455 -0
  14. lodash/index.d.ts +11 -338
  15. lodash/package.json +2 -7
  16. lodash/array/chunk.d.ts +0 -37
  17. lodash/array/compact.d.ts +0 -27
  18. lodash/array/concat.d.ts +0 -39
  19. lodash/array/difference.d.ts +0 -37
  20. lodash/array/differenceBy.d.ts +0 -243
  21. lodash/array/differenceWith.d.ts +0 -132
  22. lodash/array/drop.d.ts +0 -27
  23. lodash/array/dropRight.d.ts +0 -30
  24. lodash/array/dropRightWhile.d.ts +0 -47
  25. lodash/array/dropWhile.d.ts +0 -47
  26. lodash/array/fill.d.ts +0 -124
  27. lodash/array/findIndex.d.ts +0 -50
  28. lodash/array/findLastIndex.d.ts +0 -49
  29. lodash/array/first.d.ts +0 -23
  30. lodash/array/flatten.d.ts +0 -43
  31. lodash/array/flattenDeep.d.ts +0 -26
  32. lodash/array/flattenDepth.d.ts +0 -27
  33. lodash/array/fromPairs.d.ts +0 -59
  34. lodash/array/head.d.ts +0 -28
  35. lodash/array/indexOf.d.ts +0 -53
  36. lodash/array/initial.d.ts +0 -26
  37. lodash/array/intersection.d.ts +0 -33
  38. lodash/array/intersectionBy.d.ts +0 -134
  39. lodash/array/intersectionWith.d.ts +0 -133
  40. lodash/array/join.d.ts +0 -30
  41. lodash/array/last.d.ts +0 -26
  42. lodash/array/lastIndexOf.d.ts +0 -40
  43. lodash/array/nth.d.ts +0 -36
  44. lodash/array/pull.d.ts +0 -46
  45. lodash/array/pullAll.d.ts +0 -54
  46. lodash/array/pullAllBy.d.ts +0 -77
  47. lodash/array/pullAllWith.d.ts +0 -77
  48. lodash/array/pullAt.d.ts +0 -34
  49. lodash/array/remove.d.ts +0 -49
  50. lodash/array/reverse.d.ts +0 -27
  51. lodash/array/slice.d.ts +0 -40
  52. lodash/array/sortedIndex.d.ts +0 -45
  53. lodash/array/sortedIndexBy.d.ts +0 -97
  54. lodash/array/sortedIndexOf.d.ts +0 -42
  55. lodash/array/sortedLastIndex.d.ts +0 -43
  56. lodash/array/sortedLastIndexBy.d.ts +0 -48
  57. lodash/array/sortedLastIndexOf.d.ts +0 -42
  58. lodash/array/sortedUniq.d.ts +0 -34
  59. lodash/array/sortedUniqBy.d.ts +0 -66
  60. lodash/array/tail.d.ts +0 -26
  61. lodash/array/take.d.ts +0 -36
  62. lodash/array/takeRight.d.ts +0 -36
  63. lodash/array/takeRightWhile.d.ts +0 -47
  64. lodash/array/takeWhile.d.ts +0 -47
  65. lodash/array/union.d.ts +0 -33
  66. lodash/array/unionBy.d.ts +0 -164
  67. lodash/array/unionWith.d.ts +0 -103
  68. lodash/array/uniq.d.ts +0 -36
  69. lodash/array/uniqBy.d.ts +0 -71
  70. lodash/array/uniqWith.d.ts +0 -45
  71. lodash/array/unzip.d.ts +0 -27
  72. lodash/array/unzipWith.d.ts +0 -60
  73. lodash/array/without.d.ts +0 -36
  74. lodash/array/xor.d.ts +0 -32
  75. lodash/array/xorBy.d.ts +0 -104
  76. lodash/array/xorWith.d.ts +0 -103
  77. lodash/array/zip.d.ts +0 -129
  78. lodash/array/zipObject.d.ts +0 -58
  79. lodash/array/zipObjectDeep.d.ts +0 -36
  80. lodash/array/zipWith.d.ts +0 -187
  81. lodash/collection/countBy.d.ts +0 -121
  82. lodash/collection/each.d.ts +0 -40
  83. lodash/collection/eachRight.d.ts +0 -40
  84. lodash/collection/every.d.ts +0 -85
  85. lodash/collection/filter.d.ts +0 -143
  86. lodash/collection/find.d.ts +0 -131
  87. lodash/collection/findLast.d.ts +0 -121
  88. lodash/collection/flatMap.d.ts +0 -164
  89. lodash/collection/flatMapDeep.d.ts +0 -164
  90. lodash/collection/flatMapDepth.d.ts +0 -180
  91. lodash/collection/forEach.d.ts +0 -113
  92. lodash/collection/forEachRight.d.ts +0 -108
  93. lodash/collection/groupBy.d.ts +0 -121
  94. lodash/collection/includes.d.ts +0 -41
  95. lodash/collection/invokeMap.d.ts +0 -58
  96. lodash/collection/keyBy.d.ts +0 -121
  97. lodash/collection/map.d.ts +0 -180
  98. lodash/collection/orderBy.d.ts +0 -192
  99. lodash/collection/partition.d.ts +0 -72
  100. lodash/collection/reduce.d.ts +0 -220
  101. lodash/collection/reduceRight.d.ts +0 -217
  102. lodash/collection/reject.d.ts +0 -86
  103. lodash/collection/sample.d.ts +0 -74
  104. lodash/collection/sampleSize.d.ts +0 -60
  105. lodash/collection/shuffle.d.ts +0 -41
  106. lodash/collection/size.d.ts +0 -27
  107. lodash/collection/some.d.ts +0 -85
  108. lodash/collection/sortBy.d.ts +0 -84
  109. lodash/function/after.d.ts +0 -30
  110. lodash/function/ary.d.ts +0 -30
  111. lodash/function/before.d.ts +0 -32
  112. lodash/function/bind.d.ts +0 -50
  113. lodash/function/bindKey.d.ts +0 -51
  114. lodash/function/curry.d.ts +0 -203
  115. lodash/function/curryRight.d.ts +0 -132
  116. lodash/function/debounce.d.ts +0 -67
  117. lodash/function/defer.d.ts +0 -31
  118. lodash/function/delay.d.ts +0 -38
  119. lodash/function/flip.d.ts +0 -28
  120. lodash/function/memoize.d.ts +0 -37
  121. lodash/function/negate.d.ts +0 -20
  122. lodash/function/once.d.ts +0 -20
  123. lodash/function/overArgs.d.ts +0 -31
  124. lodash/function/partial.d.ts +0 -159
  125. lodash/function/partialRight.d.ts +0 -150
  126. lodash/function/rearg.d.ts +0 -28
  127. lodash/function/rest.d.ts +0 -33
  128. lodash/function/spread.d.ts +0 -44
  129. lodash/function/throttle.d.ts +0 -58
  130. lodash/function/unary.d.ts +0 -32
  131. lodash/function/wrap.d.ts +0 -61
  132. lodash/lang/castArray.d.ts +0 -26
  133. lodash/lang/clone.d.ts +0 -31
  134. lodash/lang/cloneDeep.d.ts +0 -26
  135. lodash/lang/cloneDeepWith.d.ts +0 -51
  136. lodash/lang/cloneWith.d.ts +0 -74
  137. lodash/lang/conformsTo.d.ts +0 -31
  138. lodash/lang/eq.d.ts +0 -55
  139. lodash/lang/gt.d.ts +0 -30
  140. lodash/lang/gte.d.ts +0 -30
  141. lodash/lang/isArguments.d.ts +0 -26
  142. lodash/lang/isArray.d.ts +0 -31
  143. lodash/lang/isArrayBuffer.d.ts +0 -26
  144. lodash/lang/isArrayLike.d.ts +0 -52
  145. lodash/lang/isArrayLikeObject.d.ts +0 -53
  146. lodash/lang/isBoolean.d.ts +0 -26
  147. lodash/lang/isBuffer.d.ts +0 -26
  148. lodash/lang/isDate.d.ts +0 -26
  149. lodash/lang/isElement.d.ts +0 -26
  150. lodash/lang/isEmpty.d.ts +0 -27
  151. lodash/lang/isEqual.d.ts +0 -52
  152. lodash/lang/isEqualWith.d.ts +0 -61
  153. lodash/lang/isError.d.ts +0 -27
  154. lodash/lang/isFinite.d.ts +0 -28
  155. lodash/lang/isFunction.d.ts +0 -26
  156. lodash/lang/isInteger.d.ts +0 -42
  157. lodash/lang/isLength.d.ts +0 -42
  158. lodash/lang/isMap.d.ts +0 -26
  159. lodash/lang/isMatch.d.ts +0 -42
  160. lodash/lang/isMatchWith.d.ts +0 -51
  161. lodash/lang/isNaN.d.ts +0 -28
  162. lodash/lang/isNative.d.ts +0 -26
  163. lodash/lang/isNil.d.ts +0 -37
  164. lodash/lang/isNull.d.ts +0 -26
  165. lodash/lang/isNumber.d.ts +0 -28
  166. lodash/lang/isObject.d.ts +0 -27
  167. lodash/lang/isObjectLike.d.ts +0 -41
  168. lodash/lang/isPlainObject.d.ts +0 -29
  169. lodash/lang/isRegExp.d.ts +0 -26
  170. lodash/lang/isSafeInteger.d.ts +0 -43
  171. lodash/lang/isSet.d.ts +0 -26
  172. lodash/lang/isString.d.ts +0 -26
  173. lodash/lang/isSymbol.d.ts +0 -34
  174. lodash/lang/isTypedArray.d.ts +0 -26
  175. lodash/lang/isUndefined.d.ts +0 -26
  176. lodash/lang/isWeakMap.d.ts +0 -26
  177. lodash/lang/isWeakSet.d.ts +0 -26
  178. lodash/lang/lt.d.ts +0 -30
  179. lodash/lang/lte.d.ts +0 -30
  180. lodash/lang/toArray.d.ts +0 -46
  181. lodash/lang/toFinite.d.ts +0 -41
  182. lodash/lang/toInteger.d.ts +0 -42
  183. lodash/lang/toLength.d.ts +0 -43
  184. lodash/lang/toNumber.d.ts +0 -40
  185. lodash/lang/toPlainObject.d.ts +0 -27
  186. lodash/lang/toSafeInteger.d.ts +0 -41
  187. lodash/lang/toString.d.ts +0 -24
  188. lodash/math/add.d.ts +0 -30
  189. lodash/math/ceil.d.ts +0 -30
  190. lodash/math/divide.d.ts +0 -30
  191. lodash/math/floor.d.ts +0 -30
  192. lodash/math/max.d.ts +0 -30
  193. lodash/math/maxBy.d.ts +0 -49
  194. lodash/math/mean.d.ts +0 -33
  195. lodash/math/meanBy.d.ts +0 -41
  196. lodash/math/min.d.ts +0 -30
  197. lodash/math/minBy.d.ts +0 -49
  198. lodash/math/multiply.d.ts +0 -29
  199. lodash/math/round.d.ts +0 -30
  200. lodash/math/subtract.d.ts +0 -39
  201. lodash/math/sum.d.ts +0 -31
  202. lodash/math/sumBy.d.ts +0 -53
  203. lodash/number/clamp.d.ts +0 -56
  204. lodash/number/inRange.d.ts +0 -39
  205. lodash/object/assign.d.ts +0 -172
  206. lodash/object/assignIn.d.ts +0 -171
  207. lodash/object/assignInWith.d.ts +0 -183
  208. lodash/object/assignWith.d.ts +0 -180
  209. lodash/object/at.d.ts +0 -61
  210. lodash/object/create.d.ts +0 -31
  211. lodash/object/defaults.d.ts +0 -155
  212. lodash/object/defaultsDeep.d.ts +0 -28
  213. lodash/object/entries.d.ts +0 -38
  214. lodash/object/entriesIn.d.ts +0 -38
  215. lodash/object/extend.d.ts +0 -147
  216. lodash/object/extendWith.d.ts +0 -159
  217. lodash/object/findKey.d.ts +0 -47
  218. lodash/object/findLastKey.d.ts +0 -46
  219. lodash/object/forIn.d.ts +0 -37
  220. lodash/object/forInRight.d.ts +0 -35
  221. lodash/object/forOwn.d.ts +0 -37
  222. lodash/object/forOwnRight.d.ts +0 -35
  223. lodash/object/functions.d.ts +0 -39
  224. lodash/object/functionsIn.d.ts +0 -39
  225. lodash/object/get.d.ts +0 -238
  226. lodash/object/has.d.ts +0 -47
  227. lodash/object/hasIn.d.ts +0 -46
  228. lodash/object/invert.d.ts +0 -30
  229. lodash/object/invertBy.d.ts +0 -62
  230. lodash/object/invoke.d.ts +0 -33
  231. lodash/object/keys.d.ts +0 -28
  232. lodash/object/keysIn.d.ts +0 -28
  233. lodash/object/mapKeys.d.ts +0 -86
  234. lodash/object/mapValues.d.ts +0 -189
  235. lodash/object/merge.d.ts +0 -156
  236. lodash/object/mergeWith.d.ts +0 -133
  237. lodash/object/omit.d.ts +0 -69
  238. lodash/object/omitBy.d.ts +0 -45
  239. lodash/object/pick.d.ts +0 -68
  240. lodash/object/pickBy.d.ts +0 -44
  241. lodash/object/result.d.ts +0 -39
  242. lodash/object/set.d.ts +0 -65
  243. lodash/object/setWith.d.ts +0 -71
  244. lodash/object/toPairs.d.ts +0 -41
  245. lodash/object/toPairsIn.d.ts +0 -41
  246. lodash/object/transform.d.ts +0 -163
  247. lodash/object/unset.d.ts +0 -32
  248. lodash/object/update.d.ts +0 -39
  249. lodash/object/updateWith.d.ts +0 -83
  250. lodash/object/values.d.ts +0 -56
  251. lodash/object/valuesIn.d.ts +0 -41
  252. lodash/seq/chain.d.ts +0 -26
  253. lodash/seq/prototype.at.d.ts +0 -12
  254. lodash/seq/prototype.chain.d.ts +0 -26
  255. lodash/seq/prototype.commit.d.ts +0 -11
  256. lodash/seq/prototype.plant.d.ts +0 -18
  257. lodash/seq/prototype.reverse.d.ts +0 -14
  258. lodash/seq/prototype.toJSON.d.ts +0 -9
  259. lodash/seq/prototype.toString.d.ts +0 -11
  260. lodash/seq/prototype.value.d.ts +0 -13
  261. lodash/seq/prototype.valueOf.d.ts +0 -9
  262. lodash/seq/tap.d.ts +0 -28
  263. lodash/seq/thru.d.ts +0 -31
  264. lodash/string/camelCase.d.ts +0 -26
  265. lodash/string/capitalize.d.ts +0 -26
  266. lodash/string/deburr.d.ts +0 -27
  267. lodash/string/endsWith.d.ts +0 -38
  268. lodash/string/escape.d.ts +0 -37
  269. lodash/string/escapeRegExp.d.ts +0 -27
  270. lodash/string/kebabCase.d.ts +0 -26
  271. lodash/string/lowerCase.d.ts +0 -26
  272. lodash/string/lowerFirst.d.ts +0 -26
  273. lodash/string/pad.d.ts +0 -39
  274. lodash/string/padEnd.d.ts +0 -39
  275. lodash/string/padStart.d.ts +0 -39
  276. lodash/string/parseInt.d.ts +0 -33
  277. lodash/string/repeat.d.ts +0 -32
  278. lodash/string/replace.d.ts +0 -59
  279. lodash/string/snakeCase.d.ts +0 -26
  280. lodash/string/split.d.ts +0 -56
  281. lodash/string/startCase.d.ts +0 -26
  282. lodash/string/startsWith.d.ts +0 -38
  283. lodash/string/template.d.ts +0 -61
  284. lodash/string/toLower.d.ts +0 -26
  285. lodash/string/toUpper.d.ts +0 -26
  286. lodash/string/trim.d.ts +0 -44
  287. lodash/string/trimEnd.d.ts +0 -44
  288. lodash/string/trimStart.d.ts +0 -44
  289. lodash/string/truncate.d.ts +0 -40
  290. lodash/string/unescape.d.ts +0 -30
  291. lodash/string/upperCase.d.ts +0 -26
  292. lodash/string/upperFirst.d.ts +0 -26
  293. lodash/string/words.d.ts +0 -44
  294. lodash/util/attempt.d.ts +0 -27
  295. lodash/util/bindAll.d.ts +0 -28
  296. lodash/util/cond.d.ts +0 -33
  297. lodash/util/conforms.d.ts +0 -28
  298. lodash/util/constant.d.ts +0 -26
  299. lodash/util/defaultTo.d.ts +0 -53
  300. lodash/util/flow.d.ts +0 -171
  301. lodash/util/flowRight.d.ts +0 -156
  302. lodash/util/identity.d.ts +0 -31
  303. lodash/util/iteratee.d.ts +0 -58
  304. lodash/util/matches.d.ts +0 -36
  305. lodash/util/matchesProperty.d.ts +0 -59
  306. lodash/util/method.d.ts +0 -31
  307. lodash/util/methodOf.d.ts +0 -35
  308. lodash/util/mixin.d.ts +0 -69
  309. lodash/util/noConflict.d.ts +0 -25
  310. lodash/util/noop.d.ts +0 -25
  311. lodash/util/nthArg.d.ts +0 -26
  312. lodash/util/over.d.ts +0 -33
  313. lodash/util/overEvery.d.ts +0 -27
  314. lodash/util/overSome.d.ts +0 -27
  315. lodash/util/property.d.ts +0 -26
  316. lodash/util/propertyOf.d.ts +0 -27
  317. lodash/util/range.d.ts +0 -56
  318. lodash/util/rangeRight.d.ts +0 -77
  319. lodash/util/runInContext.d.ts +0 -19
  320. lodash/util/stubArray.d.ts +0 -25
  321. lodash/util/stubFalse.d.ts +0 -25
  322. lodash/util/stubObject.d.ts +0 -25
  323. lodash/util/stubString.d.ts +0 -25
  324. lodash/util/stubTrue.d.ts +0 -25
  325. lodash/util/times.d.ts +0 -50
  326. lodash/util/toPath.d.ts +0 -43
  327. lodash/util/uniqueId.d.ts +0 -26
@@ -0,0 +1,536 @@
1
+ import _ = require("../index");
2
+ declare module "../index" {
3
+ // add
4
+
5
+ interface LoDashStatic {
6
+ /**
7
+ * Adds two numbers.
8
+ *
9
+ * @param augend The first number to add.
10
+ * @param addend The second number to add.
11
+ * @return Returns the sum.
12
+ */
13
+ add(
14
+ augend: number,
15
+ addend: number
16
+ ): number;
17
+ }
18
+
19
+ interface LoDashImplicitWrapper<TValue> {
20
+ /**
21
+ * @see _.add
22
+ */
23
+ add(addend: number): number;
24
+ }
25
+
26
+ interface LoDashExplicitWrapper<TValue> {
27
+ /**
28
+ * @see _.add
29
+ */
30
+ add(addend: number): LoDashExplicitWrapper<number>;
31
+ }
32
+
33
+ // ceil
34
+
35
+ interface LoDashStatic {
36
+ /**
37
+ * Calculates n rounded up to precision.
38
+ *
39
+ * @param n The number to round up.
40
+ * @param precision The precision to round up to.
41
+ * @return Returns the rounded up number.
42
+ */
43
+ ceil(
44
+ n: number,
45
+ precision?: number
46
+ ): number;
47
+ }
48
+
49
+ interface LoDashImplicitWrapper<TValue> {
50
+ /**
51
+ * @see _.ceil
52
+ */
53
+ ceil(precision?: number): number;
54
+ }
55
+
56
+ interface LoDashExplicitWrapper<TValue> {
57
+ /**
58
+ * @see _.ceil
59
+ */
60
+ ceil(precision?: number): LoDashExplicitWrapper<number>;
61
+ }
62
+
63
+ // divide
64
+
65
+ interface LoDashStatic {
66
+ /**
67
+ * Divide two numbers.
68
+ *
69
+ * @param dividend The first number in a division.
70
+ * @param divisor The second number in a division.
71
+ * @returns Returns the quotient.
72
+ */
73
+ divide(
74
+ dividend: number,
75
+ divisor: number
76
+ ): number;
77
+ }
78
+
79
+ interface LoDashImplicitWrapper<TValue> {
80
+ /**
81
+ * @see _.divide
82
+ */
83
+ divide(divisor: number): number;
84
+ }
85
+
86
+ interface LoDashExplicitWrapper<TValue> {
87
+ /**
88
+ * @see _.divide
89
+ */
90
+ divide(divisor: number): LoDashExplicitWrapper<number>;
91
+ }
92
+
93
+ // floor
94
+
95
+ interface LoDashStatic {
96
+ /**
97
+ * Calculates n rounded down to precision.
98
+ *
99
+ * @param n The number to round down.
100
+ * @param precision The precision to round down to.
101
+ * @return Returns the rounded down number.
102
+ */
103
+ floor(
104
+ n: number,
105
+ precision?: number
106
+ ): number;
107
+ }
108
+
109
+ interface LoDashImplicitWrapper<TValue> {
110
+ /**
111
+ * @see _.floor
112
+ */
113
+ floor(precision?: number): number;
114
+ }
115
+
116
+ interface LoDashExplicitWrapper<TValue> {
117
+ /**
118
+ * @see _.floor
119
+ */
120
+ floor(precision?: number): LoDashExplicitWrapper<number>;
121
+ }
122
+
123
+ // max
124
+
125
+ interface LoDashStatic {
126
+ /**
127
+ * Computes the maximum value of `array`. If `array` is empty or falsey
128
+ * `undefined` is returned.
129
+ *
130
+ * @category Math
131
+ * @param array The array to iterate over.
132
+ * @returns Returns the maximum value.
133
+ */
134
+ max<T>(
135
+ collection: List<T> | null | undefined
136
+ ): T | undefined;
137
+ }
138
+
139
+ interface LoDashImplicitWrapper<TValue> {
140
+ /**
141
+ * @see _.max
142
+ */
143
+ max<T>(this: LoDashImplicitWrapper<List<T> | null | undefined>): T | undefined;
144
+ }
145
+
146
+ interface LoDashExplicitWrapper<TValue> {
147
+ /**
148
+ * @see _.max
149
+ */
150
+ max<T>(this: LoDashExplicitWrapper<List<T> | null | undefined>): LoDashExplicitWrapper<T | undefined>;
151
+ }
152
+
153
+ // maxBy
154
+
155
+ interface LoDashStatic {
156
+ /**
157
+ * This method is like `_.max` except that it accepts `iteratee` which is
158
+ * invoked for each element in `array` to generate the criterion by which
159
+ * the value is ranked. The iteratee is invoked with one argument: (value).
160
+ *
161
+ * @category Math
162
+ * @param array The array to iterate over.
163
+ * @param [iteratee=_.identity] The iteratee invoked per element.
164
+ * @returns Returns the maximum value.
165
+ * @example
166
+ *
167
+ * var objects = [{ 'n': 1 }, { 'n': 2 }];
168
+ *
169
+ * _.maxBy(objects, function(o) { return o.a; });
170
+ * // => { 'n': 2 }
171
+ *
172
+ * // using the `_.property` iteratee shorthand
173
+ * _.maxBy(objects, 'n');
174
+ * // => { 'n': 2 }
175
+ */
176
+ maxBy<T>(
177
+ collection: List<T> | null | undefined,
178
+ iteratee?: ListIteratee<T>
179
+ ): T | undefined;
180
+ }
181
+
182
+ interface LoDashImplicitWrapper<TValue> {
183
+ /**
184
+ * @see _.maxBy
185
+ */
186
+ maxBy<T>(
187
+ this: LoDashImplicitWrapper<List<T> | null | undefined>,
188
+ iteratee?: ListIteratee<T>
189
+ ): T | undefined;
190
+ }
191
+
192
+ interface LoDashExplicitWrapper<TValue> {
193
+ /**
194
+ * @see _.maxBy
195
+ */
196
+ maxBy<T>(
197
+ this: LoDashExplicitWrapper<List<T> | null | undefined>,
198
+ iteratee?: ListIteratee<T>
199
+ ): LoDashExplicitWrapper<T | undefined>;
200
+ }
201
+
202
+ // mean
203
+
204
+ interface LoDashStatic {
205
+ /**
206
+ * Computes the mean of the values in `array`.
207
+ *
208
+ * @category Math
209
+ * @param array The array to iterate over.
210
+ * @returns Returns the mean.
211
+ * @example
212
+ *
213
+ * _.mean([4, 2, 8, 6]);
214
+ * // => 5
215
+ */
216
+ mean(
217
+ collection: List<any> | null | undefined
218
+ ): number;
219
+ }
220
+
221
+ interface LoDashImplicitWrapper<TValue> {
222
+ /**
223
+ * @see _.mean
224
+ */
225
+ mean(): number;
226
+ }
227
+
228
+ interface LoDashExplicitWrapper<TValue> {
229
+ /**
230
+ * @see _.mean
231
+ */
232
+ mean(): LoDashExplicitWrapper<number>;
233
+ }
234
+
235
+ // meanBy
236
+
237
+ interface LoDashStatic {
238
+ /**
239
+ * Computes the mean of the provided propties of the objects in the `array`
240
+ *
241
+ * @category Math
242
+ * @param array The array to iterate over.
243
+ * @param [iteratee=_.identity] The iteratee invoked per element.
244
+ * @returns Returns the mean.
245
+ * @example
246
+ *
247
+ * _.mean([{ 'n': 4 }, { 'n': 2 }, { 'n': 8 }, { 'n': 6 }], 'n');
248
+ * // => 5
249
+ */
250
+ meanBy<T>(
251
+ collection: List<T> | null | undefined,
252
+ iteratee?: ListIteratee<T>
253
+ ): number;
254
+ }
255
+
256
+ interface LoDashImplicitWrapper<TValue> {
257
+ /**
258
+ * @see _.meanBy
259
+ */
260
+ meanBy<T>(
261
+ this: LoDashImplicitWrapper<List<T> | null | undefined>,
262
+ iteratee?: ListIteratee<T>
263
+ ): number;
264
+ }
265
+
266
+ interface LoDashExplicitWrapper<TValue> {
267
+ /**
268
+ * @see _.meanBy
269
+ */
270
+ meanBy<T>(
271
+ this: LoDashExplicitWrapper<List<T> | null | undefined>,
272
+ iteratee?: ListIteratee<T>
273
+ ): LoDashExplicitWrapper<number>;
274
+ }
275
+
276
+ // min
277
+
278
+ interface LoDashStatic {
279
+ /**
280
+ * Computes the minimum value of `array`. If `array` is empty or falsey
281
+ * `undefined` is returned.
282
+ *
283
+ * @category Math
284
+ * @param array The array to iterate over.
285
+ * @returns Returns the minimum value.
286
+ */
287
+ min<T>(
288
+ collection: List<T> | null | undefined
289
+ ): T | undefined;
290
+ }
291
+
292
+ interface LoDashImplicitWrapper<TValue> {
293
+ /**
294
+ * @see _.min
295
+ */
296
+ min<T>(this: LoDashImplicitWrapper<List<T> | null | undefined>): T | undefined;
297
+ }
298
+
299
+ interface LoDashExplicitWrapper<TValue> {
300
+ /**
301
+ * @see _.min
302
+ */
303
+ min<T>(this: LoDashExplicitWrapper<List<T> | null | undefined>): LoDashExplicitWrapper<T | undefined>;
304
+ }
305
+
306
+ // minBy
307
+
308
+ interface LoDashStatic {
309
+ /**
310
+ * This method is like `_.min` except that it accepts `iteratee` which is
311
+ * invoked for each element in `array` to generate the criterion by which
312
+ * the value is ranked. The iteratee is invoked with one argument: (value).
313
+ *
314
+ * @category Math
315
+ * @param array The array to iterate over.
316
+ * @param [iteratee=_.identity] The iteratee invoked per element.
317
+ * @returns Returns the minimum value.
318
+ * @example
319
+ *
320
+ * var objects = [{ 'n': 1 }, { 'n': 2 }];
321
+ *
322
+ * _.minBy(objects, function(o) { return o.a; });
323
+ * // => { 'n': 1 }
324
+ *
325
+ * // using the `_.property` iteratee shorthand
326
+ * _.minBy(objects, 'n');
327
+ * // => { 'n': 1 }
328
+ */
329
+ minBy<T>(
330
+ collection: List<T> | null | undefined,
331
+ iteratee?: ListIteratee<T>
332
+ ): T | undefined;
333
+ }
334
+
335
+ interface LoDashImplicitWrapper<TValue> {
336
+ /**
337
+ * @see _.minBy
338
+ */
339
+ minBy<T>(
340
+ this: LoDashImplicitWrapper<List<T> | null | undefined>,
341
+ iteratee?: ListIteratee<T>
342
+ ): T | undefined;
343
+ }
344
+
345
+ interface LoDashExplicitWrapper<TValue> {
346
+ /**
347
+ * @see _.minBy
348
+ */
349
+ minBy<T>(
350
+ this: LoDashExplicitWrapper<List<T> | null | undefined>,
351
+ iteratee?: ListIteratee<T>
352
+ ): LoDashExplicitWrapper<T | undefined>;
353
+ }
354
+
355
+ // multiply
356
+
357
+ interface LoDashStatic {
358
+ /**
359
+ * Multiply two numbers.
360
+ * @param multiplier The first number in a multiplication.
361
+ * @param multiplicand The second number in a multiplication.
362
+ * @returns Returns the product.
363
+ */
364
+ multiply(
365
+ multiplier: number,
366
+ multiplicand: number
367
+ ): number;
368
+ }
369
+
370
+ interface LoDashImplicitWrapper<TValue> {
371
+ /**
372
+ * @see _.multiply
373
+ */
374
+ multiply(multiplicand: number): number;
375
+ }
376
+
377
+ interface LoDashExplicitWrapper<TValue> {
378
+ /**
379
+ * @see _.multiply
380
+ */
381
+ multiply(multiplicand: number): LoDashExplicitWrapper<number>;
382
+ }
383
+
384
+ // round
385
+
386
+ interface LoDashStatic {
387
+ /**
388
+ * Calculates n rounded to precision.
389
+ *
390
+ * @param n The number to round.
391
+ * @param precision The precision to round to.
392
+ * @return Returns the rounded number.
393
+ */
394
+ round(
395
+ n: number,
396
+ precision?: number
397
+ ): number;
398
+ }
399
+
400
+ interface LoDashImplicitWrapper<TValue> {
401
+ /**
402
+ * @see _.round
403
+ */
404
+ round(precision?: number): number;
405
+ }
406
+
407
+ interface LoDashExplicitWrapper<TValue> {
408
+ /**
409
+ * @see _.round
410
+ */
411
+ round(precision?: number): LoDashExplicitWrapper<number>;
412
+ }
413
+
414
+ // subtract
415
+
416
+ interface LoDashStatic {
417
+ /**
418
+ * Subtract two numbers.
419
+ *
420
+ * @category Math
421
+ * @param minuend The first number in a subtraction.
422
+ * @param subtrahend The second number in a subtraction.
423
+ * @returns Returns the difference.
424
+ * @example
425
+ *
426
+ * _.subtract(6, 4);
427
+ * // => 2
428
+ */
429
+ subtract(
430
+ minuend: number,
431
+ subtrahend: number
432
+ ): number;
433
+ }
434
+
435
+ interface LoDashImplicitWrapper<TValue> {
436
+ /**
437
+ * @see _.subtract
438
+ */
439
+ subtract(
440
+ subtrahend: number
441
+ ): number;
442
+ }
443
+
444
+ interface LoDashExplicitWrapper<TValue> {
445
+ /**
446
+ * @see _.subtract
447
+ */
448
+ subtract(
449
+ subtrahend: number
450
+ ): LoDashExplicitWrapper<number>;
451
+ }
452
+
453
+ // sum
454
+
455
+ interface LoDashStatic {
456
+ /**
457
+ * Computes the sum of the values in `array`.
458
+ *
459
+ * @category Math
460
+ * @param array The array to iterate over.
461
+ * @returns Returns the sum.
462
+ * @example
463
+ *
464
+ * _.sum([4, 2, 8, 6]);
465
+ * // => 20
466
+ */
467
+ sum(collection: List<any> | null | undefined): number;
468
+ }
469
+
470
+ interface LoDashImplicitWrapper<TValue> {
471
+ /**
472
+ * @see _.sum
473
+ */
474
+ sum(): number;
475
+ }
476
+
477
+ interface LoDashExplicitWrapper<TValue> {
478
+ /**
479
+ * @see _.sum
480
+ */
481
+ sum(): LoDashExplicitWrapper<number>;
482
+ }
483
+
484
+ // sumBy
485
+
486
+ interface LoDashStatic {
487
+ /**
488
+ * This method is like `_.sum` except that it accepts `iteratee` which is
489
+ * invoked for each element in `array` to generate the value to be summed.
490
+ * The iteratee is invoked with one argument: (value).
491
+ *
492
+ * @category Math
493
+ * @param array The array to iterate over.
494
+ * @param [iteratee=_.identity] The iteratee invoked per element.
495
+ * @returns Returns the sum.
496
+ * @example
497
+ *
498
+ * var objects = [{ 'n': 4 }, { 'n': 2 }, { 'n': 8 }, { 'n': 6 }];
499
+ *
500
+ * _.sumBy(objects, function(o) { return o.n; });
501
+ * // => 20
502
+ *
503
+ * // using the `_.property` iteratee shorthand
504
+ * _.sumBy(objects, 'n');
505
+ * // => 20
506
+ */
507
+ sumBy<T>(
508
+ collection: List<T> | null | undefined,
509
+ iteratee?: ((value: T) => number) | string
510
+ ): number;
511
+ }
512
+
513
+ interface LoDashImplicitWrapper<TValue> {
514
+ /**
515
+ * @see _.sumBy
516
+ */
517
+ sumBy<T>(
518
+ this: LoDashImplicitWrapper<List<T> | null | undefined>,
519
+ iteratee?: ((value: T) => number) | string
520
+ ): number;
521
+ }
522
+
523
+ interface LoDashExplicitWrapper<TValue> {
524
+ /**
525
+ * @see _.sumBy
526
+ */
527
+ sumBy<T>(
528
+ this: LoDashExplicitWrapper<List<T> | null | undefined>,
529
+ iteratee?: ((value: T) => number) | string
530
+ ): LoDashExplicitWrapper<number>;
531
+ }
532
+
533
+ /**********
534
+ * Number *
535
+ **********/
536
+ }
@@ -1,5 +1,102 @@
1
- import * as _ from "../index";
1
+ import _ = require("../index");
2
2
  declare module "../index" {
3
+ // clamp
4
+
5
+ interface LoDashStatic {
6
+ /**
7
+ * Clamps `number` within the inclusive `lower` and `upper` bounds.
8
+ *
9
+ * @category Number
10
+ * @param number The number to clamp.
11
+ * @param [lower] The lower bound.
12
+ * @param upper The upper bound.
13
+ * @returns Returns the clamped number.
14
+ * @example
15
+ *
16
+ * _.clamp(-10, -5, 5);
17
+ * // => -5
18
+ *
19
+ * _.clamp(10, -5, 5);
20
+ * // => 5
21
+ */
22
+ clamp(
23
+ number: number,
24
+ lower: number,
25
+ upper: number
26
+ ): number;
27
+ clamp(
28
+ number: number,
29
+ upper: number
30
+ ): number;
31
+ }
32
+
33
+ interface LoDashImplicitWrapper<TValue> {
34
+ /**
35
+ * @see _.clamp
36
+ */
37
+ clamp(
38
+ lower: number,
39
+ upper: number
40
+ ): number;
41
+ clamp(
42
+ upper: number
43
+ ): number;
44
+ }
45
+
46
+ interface LoDashExplicitWrapper<TValue> {
47
+ /**
48
+ * @see _.clamp
49
+ */
50
+ clamp(
51
+ lower: number,
52
+ upper: number
53
+ ): LoDashExplicitWrapper<number>;
54
+ clamp(
55
+ upper: number
56
+ ): LoDashExplicitWrapper<number>;
57
+ }
58
+
59
+ // inRange
60
+
61
+ interface LoDashStatic {
62
+ /**
63
+ * Checks if n is between start and up to but not including, end. If end is not specified it’s set to start
64
+ * with start then set to 0.
65
+ *
66
+ * @param n The number to check.
67
+ * @param start The start of the range.
68
+ * @param end The end of the range.
69
+ * @return Returns true if n is in the range, else false.
70
+ */
71
+ inRange(
72
+ n: number,
73
+ start: number,
74
+ end?: number
75
+ ): boolean;
76
+ }
77
+
78
+ interface LoDashImplicitWrapper<TValue> {
79
+ /**
80
+ * @see _.inRange
81
+ */
82
+ inRange(
83
+ start: number,
84
+ end?: number
85
+ ): boolean;
86
+ }
87
+
88
+ interface LoDashExplicitWrapper<TValue> {
89
+ /**
90
+ * @see _.inRange
91
+ */
92
+ inRange(
93
+ start: number,
94
+ end?: number
95
+ ): LoDashExplicitWrapper<boolean>;
96
+ }
97
+
98
+ // random
99
+
3
100
  interface LoDashStatic {
4
101
  /**
5
102
  * Produces a random number between min and max (inclusive). If only one argument is provided a number between