source: node_modules/ts-toolbelt/out/Class/Parameters.d.ts@ d24f17c

main
Last change on this file since d24f17c was d24f17c, checked in by Aleksandar Panovski <apano77@…>, 15 months ago

Initial commit

  • Property mode set to 100644
File size: 431 bytes
Line 
1import { Class } from './Class';
2/**
3 * Get the parameters of a class constructor
4 * @param C **typeof** class
5 * @returns [[List]]
6 * @example
7 * ```ts
8 * import {C} from 'ts-toolbelt'
9 *
10 * type User = C.Class<[string, string], {firstname: string, lastname: string}>
11 *
12 * type test0 = C.Parameters<User> // [string, string]
13 * ```
14 */
15export declare type Parameters<C extends Class> = C extends Class<infer P, any> ? P : never;
Note: See TracBrowser for help on using the repository browser.