UNPKG

485 BTypeScriptView Raw
1import type { Codec, Registry } from '@polkadot/types-codec/types';
2import type { DetectCodec } from '../types';
3/**
4 * Create an instance of a `type` with a given `params`.
5 * @param type - A recognizable string representing the type to create an
6 * instance from
7 * @param params - The value to instantiate the type with
8 */
9export declare function createType<T extends Codec = Codec, K extends string = string>(registry: Registry, type: K, ...params: unknown[]): DetectCodec<T, K>;