Repository URL to install this package:
|
Version:
6.0.4 ▾
|
/**
* @desc Returns a function which returns its nth argument.
* @memberOf fp
* @since 5.0.0-beta.6
*
* @param n arg to get
* @see deps/argumentor
*
* @curried 1
* @tests fp/nthArg
*
* @func
* @fork v0.9.0
* @category Function
* @sig Number -> *... -> *
*
* @symb nthArg(-1)(a, b, c) = c
* @symb nthArg(0)(a, b, c) = a
* @symb nthArg(1)(a, b, c) = b
*
* @example
*
* nthArg(1)('a', 'b', 'c') //=> 'b'
* nthArg(-1)('a', 'b', 'c') //=> 'c'
*
*/
declare const nthArg: (n: number) => import("./curry").CurriedFunction1<{}, {}>;
export default nthArg;