Interface CommandConfig<TCommand, TKey>

Config for describing a command.

Used with createCommand to create command instances from configuration data. This is useful for storing command definitions or transmitting them across boundaries.

Type Parameters

  • TCommand = any

  • TKey extends string = string

Hierarchy

  • CommandConfig

Properties

Properties

id: TKey

Id of the command.

Specified by the Command decorator when declaring the command.

params?: { [ K in string | number | symbol]?: TCommand[K] }

Optional parameters to set when creating the command from the config.

All values must be serializable (primitive types, plain objects, arrays). This matches the requirement that all command properties must be serializable as defined in AnyCommand.