1 | import { LodashMethodDecorator } from './factory';
|
2 | declare const decorator: (...args: any[]) => MethodDecorator & PropertyDecorator;
|
3 | /**
|
4 | * Creates a function that invokes func with its arguments transformed.
|
5 | * @export
|
6 | * @param {...Function[]} transforms
|
7 | * @returns {LodashMethodDecorator}
|
8 | * @example
|
9 | * class MyClass {
|
10 | * @OverArgs(_.castArray)
|
11 | * fn(list) {
|
12 | * return list;
|
13 | * }
|
14 | * }
|
15 | *
|
16 | * const myClass = new MyClass();
|
17 | *
|
18 | * myClass.fn([ 1 ]); //=> [ 1 ];
|
19 | * myClass.fn(1); //=> [ 1 ];
|
20 | */
|
21 | export declare function OverArgs(...transforms: Function[]): LodashMethodDecorator;
|
22 | export { OverArgs as overArgs };
|
23 | export default decorator;
|