Skip to content

ViewModelViewHost class

Defined in

Namespace: Avalonia.ReactiveUI Assembly: ReactiveUI.Avalonia.Autofac.dll Full name: Avalonia.ReactiveUI.ViewModelViewHost Modifiers: public

Summary

View source

        This content control will automatically load the View associated with
        the ViewModel property and display it. This control is very useful
        inside a DataTemplate to display the View associated with a ViewModel.
        

Applies to

netstandard2.0, netstandard2.0, netstandard2.0, netstandard2.0, netstandard2.0

Class hierarchy
classDiagram
class ViewModelViewHost
class TransitioningContentControl
TransitioningContentControl <|-- ViewModelViewHost
class IViewFor {
    <>
}
IViewFor <|.. ViewModelViewHost
class IActivatableView {
    <>
}
IActivatableView <|.. ViewModelViewHost
class IEnableLogger {
    <>
}
IEnableLogger <|.. ViewModelViewHost

Inherits from: TransitioningContentControl

Implements: IViewFor, IActivatableView, IEnableLogger

Constructors

NameSummary
.ctorInitializes a new instance of the [ViewModelViewHost](# class.

Properties

NameSummary
ViewModelGets or sets the ViewModel to display.
ViewContractGets or sets the view contract.
DefaultContentGets or sets the content displayed whenever there is no page currently routed.
ViewLocatorGets or sets the view locator.
StyleKeyOverrideGets the type by which the element is styled.

Fields

NameSummary
static ViewModelPropertyAvaloniaProperty for the [ViewModel](# property.
static ViewContractPropertyAvaloniaProperty for the [ViewContract](# property.
static DefaultContentPropertyAvaloniaProperty for the [DefaultContent](# property.
Inherited members