Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
NikolayPianikov committed Aug 6, 2024
1 parent 421163c commit a7ec131
Show file tree
Hide file tree
Showing 23 changed files with 29 additions and 29 deletions.
4 changes: 2 additions & 2 deletions readme/Avalonia.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ internal partial class Composition
{
void Setup() => DI.Setup()
// Provides the composition root for main window
.Root<MainWindow>("MainWindow")
.Root<MainWindow>(nameof(MainWindow))
// Provides the composition root for Clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))

// View Models
.Bind().As(Singleton).To<ClockViewModel>()
Expand Down
4 changes: 2 additions & 2 deletions readme/AvaloniaPageTemplate.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ internal partial class Composition
{
void Setup() => DI.Setup()
// Provides the composition root for main window
.Root<MainWindow>("MainWindow")
.Root<MainWindow>(nameof(MainWindow))
// Provides the composition root for Clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))

// View Models
.Bind().As(Singleton).To<ClockViewModel>()
Expand Down
2 changes: 1 addition & 1 deletion readme/BlazorServerApp.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ internal partial class Composition: ServiceProviderFactory<Composition>
// View Models
.Bind().To<ClockViewModel>()
// Provides the composition root for Clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))
.Bind().To<ErrorViewModel>()
// Provides the composition root for Error view model
.Root<IErrorViewModel>()
Expand Down
2 changes: 1 addition & 1 deletion readme/BlazorServerAppPageTemplate.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ internal partial class Composition: ServiceProviderFactory<Composition>
// View Models
.Bind().To<ClockViewModel>()
// Provides the composition root for Clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))
.Bind().To<ErrorViewModel>()
// Provides the composition root for Error view model
.Root<IErrorViewModel>()
Expand Down
2 changes: 1 addition & 1 deletion readme/BlazorWebAssemblyApp.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ internal partial class Composition: ServiceProviderFactory<Composition>
// View Models
.Bind().As(Singleton).To<ClockViewModel>()
// Provides the composition root for Clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))

// Services
.Bind().To<Log<TT>>()
Expand Down
2 changes: 1 addition & 1 deletion readme/BlazorWebAssemblyAppPageTemplate.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ internal partial class Composition: ServiceProviderFactory<Composition>
// View Models
.Bind().As(Singleton).To<ClockViewModel>()
// Provides the composition root for Clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))

// Services
.Bind().To<Log<TT>>()
Expand Down
4 changes: 2 additions & 2 deletions readme/Maui.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ internal partial class Composition: ServiceProviderFactory<Composition>
.Hint(Hint.OnCannotResolveContractTypeNameRegularExpression, "^Microsoft\\.(Extensions|Maui)\\..+$")

// Roots
.Root<AppShell>("AppShell")
.Root<IClockViewModel>("ClockViewModel")
.Root<AppShell>(nameof(AppShell))
.Root<IClockViewModel>(nameof(ClockViewModel))

// View Models
.Bind().As(Singleton).To<ClockViewModel>()
Expand Down
4 changes: 2 additions & 2 deletions readme/MauiPageTemplate.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ internal partial class Composition: ServiceProviderFactory<Composition>
.Hint(Hint.OnCannotResolveContractTypeNameRegularExpression, "^Microsoft\\.(Extensions|Maui)\\..+$")

// Roots
.Root<AppShell>("AppShell")
.Root<IClockViewModel>("ClockViewModel")
.Root<AppShell>(nameof(AppShell))
.Root<IClockViewModel>(nameof(ClockViewModel))

// View Models
.Bind().As(Singleton).To<ClockViewModel>()
Expand Down
2 changes: 1 addition & 1 deletion readme/WinFormsApp.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The composition definition is in the file [Composition.cs](/samples/WinFormsApp/
internal partial class Composition
{
void Setup() => DI.Setup()
.Root<FormMain>("FormMain")
.Root<FormMain>(nameof(FormMain))

// Forms
.Bind().As(Singleton).To<FormMain>()
Expand Down
2 changes: 1 addition & 1 deletion readme/WinFormsAppNetCore.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ internal partial class Composition
{
void Setup() => DI.Setup()
// Provides the composition root for main form
.Root<FormMain>("FormMain")
.Root<FormMain>(nameof(FormMain))

// Forms
.Bind().As(Singleton).To<FormMain>()
Expand Down
2 changes: 1 addition & 1 deletion readme/WinFormsAppNetCorePageTemplate.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ internal partial class Composition
{
void Setup() => DI.Setup()
// Provides the composition root for main form
.Root<FormMain>("FormMain")
.Root<FormMain>(nameof(FormMain))

// Forms
.Bind().As(Singleton).To<FormMain>()
Expand Down
2 changes: 1 addition & 1 deletion readme/WinFormsAppPageTemplate.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The composition definition is in the file [Composition.cs](/samples/WinFormsApp/
internal partial class Composition
{
void Setup() => DI.Setup()
.Root<FormMain>("FormMain")
.Root<FormMain>(nameof(FormMain))

// Forms
.Bind().As(Singleton).To<FormMain>()
Expand Down
2 changes: 1 addition & 1 deletion readme/Wpf.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ internal partial class Composition
{
void Setup() => DI.Setup()
// Provides the composition root for clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))

// View Models
.Bind().As(Singleton).To<ClockViewModel>()
Expand Down
2 changes: 1 addition & 1 deletion readme/WpfPageTemplate.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ internal partial class Composition
{
void Setup() => DI.Setup()
// Provides the composition root for clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))

// View Models
.Bind().As(Singleton).To<ClockViewModel>()
Expand Down
4 changes: 2 additions & 2 deletions samples/AvaloniaApp/Composition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ internal partial class Composition
{
void Setup() => DI.Setup()
// Provides the composition root for main window
.Root<MainWindow>("MainWindow")
.Root<MainWindow>(nameof(MainWindow))
// Provides the composition root for Clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))

// View Models
.Bind().As(Singleton).To<ClockViewModel>()
Expand Down
2 changes: 1 addition & 1 deletion samples/BlazorServerApp/Composition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ void Setup() => DI.Setup()
// View Models
.Bind().To<ClockViewModel>()
// Provides the composition root for Clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))
.Bind().To<ErrorViewModel>()
// Provides the composition root for Error view model
.Root<IErrorViewModel>()
Expand Down
2 changes: 1 addition & 1 deletion samples/BlazorWebAssemblyApp/Composition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ void Setup() => DI.Setup()
// View Models
.Bind().As(Singleton).To<ClockViewModel>()
// Provides the composition root for Clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))

// Services
.Bind().To<Log<TT>>()
Expand Down
4 changes: 2 additions & 2 deletions samples/MAUIApp/Composition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ private static void Setup() => DI.Setup()
.Hint(Hint.OnCannotResolveContractTypeNameRegularExpression, "^Microsoft\\.(Extensions|Maui)\\..+$")

// Roots
.Root<AppShell>("AppShell")
.Root<IClockViewModel>("ClockViewModel")
.Root<AppShell>(nameof(AppShell))
.Root<IClockViewModel>(nameof(ClockViewModel))

// View Models
.Bind().As(Singleton).To<ClockViewModel>()
Expand Down
2 changes: 1 addition & 1 deletion samples/MinimalWebAPI/Composition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,5 @@ void Setup() => DI.Setup()
.Root<IWeatherForecastService>()

// Application composition root
.Root<Program>("Root");
.Root<Program>(nameof(Root));
}
2 changes: 1 addition & 1 deletion samples/SingleRootAvaloniaApp/Composition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ internal partial class Composition
{
void Setup() => DI.Setup()
// A single compositional root for the application
.Root<AppDataContext>("App")
.Root<AppDataContext>(nameof(App))

.Bind().As(Singleton).To<AppDataContext>()

Expand Down
2 changes: 1 addition & 1 deletion samples/WinFormsApp/Composition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ namespace WinFormsApp;
internal partial class Composition
{
private static void Setup() => DI.Setup()
.Root<FormMain>("FormMain")
.Root<FormMain>(nameof(FormMain))

// Forms
.Bind().As(Singleton).To<FormMain>()
Expand Down
2 changes: 1 addition & 1 deletion samples/WinFormsAppNetCore/Composition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ internal partial class Composition
{
void Setup() => DI.Setup()
// Provides the composition root for main form
.Root<FormMain>("FormMain")
.Root<FormMain>(nameof(FormMain))

// Forms
.Bind().As(Singleton).To<FormMain>()
Expand Down
2 changes: 1 addition & 1 deletion samples/WpfAppNetCore/Composition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ internal partial class Composition
{
void Setup() => DI.Setup()
// Provides the composition root for clock view model
.Root<IClockViewModel>("ClockViewModel")
.Root<IClockViewModel>(nameof(ClockViewModel))

// View Models
.Bind().As(Singleton).To<ClockViewModel>()
Expand Down

0 comments on commit a7ec131

Please sign in to comment.