21 lines
535 B
C#
21 lines
535 B
C#
using Microsoft.AspNetCore.Components;
|
|
using RpgRoller.Components;
|
|
|
|
namespace RpgRoller.Components.Pages;
|
|
|
|
public partial class Home
|
|
{
|
|
[Inject]
|
|
private RpgRollerApiClient ApiClient { get; set; } = default!;
|
|
|
|
private Task<T> RequestAsync<T>(string method, string path, object? payload = null)
|
|
{
|
|
return ApiClient.RequestAsync<T>(method, path, payload);
|
|
}
|
|
|
|
private Task RequestWithoutPayloadAsync(string method, string path)
|
|
{
|
|
return ApiClient.RequestWithoutPayloadAsync(method, path);
|
|
}
|
|
}
|