Caliburn.Light is a fork of Caliburn.Micro that
- is modular/magic-free (does not include conventions)
- does not switch to UI thread automatically for everything
- integrates some ideas of Prism and MVVMLight
- uses weak events (see Weakly)
- supports
ICommand
out-of-the-box
Caliburn.Light is available through NuGet:
Install-Package Caliburn.Light
Bind.Model
(use on root nodes like Window/UserControl/Page)
Sets the DataContext and attaches the view to the view-model.Bind.ModelWithoutContext
(use inside of DataTemplate)
Attaches the view to the view-model only.
View.Model
Locates the view for the specified VM instance and injects it at the content site. Sets the VM as DataContext on the view.View.Context
To support multiple views over the same ViewModel, set this property on the injection site.
For attaching an action to a view element
CallMethodAction
Calls a method on the specified object (supports parameters and coroutines). It also maintains the Enabled state of the target element based on a guard method/property.InvokeCommandAction
Executes a specified ICommand when invoked. It also maintains the Enabled state of the target element based on the CanExecute method of the command.