presence/Desktop.UI/DI/ServiceColletionExtensions.cs
2025-04-30 04:13:44 +03:00

23 lines
635 B
C#

using Microsoft.Extensions.DependencyInjection;
using Desktop.UI.ViewModels;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.CompilerServices;
using System.Text;
using System.Threading.Tasks;
using presence_client.ApiClients;
namespace Desktop.UI.DI;
public static class ServiceColletionExtensions
{
public static void AddCommonService(this IServiceCollection collection)
{
collection
.AddSingleton<GroupApiClient>()
.AddSingleton<UserApiClient>()
.AddSingleton<PresenceApiClient>()
.AddTransient<GroupWindowViewModel>();
}
}