toType
toType(input, outputType)
toType<
T
>(input
,outputType
):null
Convert an input to a specified type. Input of null/undefined returns null/undefined regardless of the output type.
Type Parameters
• T extends TypeOutput
Parameters
• input: null
value to convert
• outputType: T
type to output
Returns
null
Defined in
node_modules/.pnpm/@ethereumjs+util@9.0.3/node_modules/@ethereumjs/util/dist/esm/types.d.ts:35
toType(input, outputType)
toType<
T
>(input
,outputType
):undefined
Type Parameters
• T extends TypeOutput
Parameters
• input: undefined
• outputType: T
Returns
undefined
Defined in
node_modules/.pnpm/@ethereumjs+util@9.0.3/node_modules/@ethereumjs/util/dist/esm/types.d.ts:36
toType(input, outputType)
toType<
T
>(input
,outputType
):TypeOutputReturnType
[T
]
Type Parameters
• T extends TypeOutput
Parameters
• input: ToBytesInputTypes
• outputType: T
Returns
TypeOutputReturnType
[T
]
Defined in
node_modules/.pnpm/@ethereumjs+util@9.0.3/node_modules/@ethereumjs/util/dist/esm/types.d.ts:37