Type alias GetConstructorArgs<TAbi, TAbiConstructor, TArgs, FailedToParseArgs>
GetConstructorArgs<TAbi, TAbiConstructor, TArgs, FailedToParseArgs>: true extends FailedToParseArgs
? {
args?: readonly unknown[];
}
: TArgs extends readonly []
? {
args?: never;
}
: {
args: TArgs;
}
Type Parameters
TAbi extends Abi | readonly unknown[]
TAbiConstructor extends AbiConstructor = TAbi extends Abi
? Extract<TAbi[number], {
type: "constructor";
}>
: AbiConstructor
FailedToParseArgs = ([TArgs] extends [never]
? true
: false) | (readonly unknown[] extends TArgs
? true
: false)