Skip to content

ViewModelType

github-actions[bot] edited this page Dec 3, 2024 · 3 revisions
API / ViewModelType<TViewModel, TConstructorArgs> alias

Represents a view model type.

type ViewModelType<TViewModel extends INotifyPropertiesChanged, TConstructorArgs extends readonly any[] = []> = {
  new (...constructorArgs: TConstructorArgs): TViewModel;
};

Source reference: src/hooks/UseViewModel.ts:12.

Generic Parameters

  • TViewModel - The type of view model.

    Type constraints: INotifyPropertiesChanged.

  • TConstructorArgs - The constructor parameter types, defaults to an empty tuple.

    Type constraints: readonly any[].
    Default value: [].

Clone this wiki locally