Files
2024-05-26 09:34:42 +09:00

22 lines
655 B
C#

using Microsoft.AspNetCore.Components.Web;
using Microsoft.AspNetCore.Components.WebAssembly.Hosting;
using R3;
namespace BlazorWebAssemblyApp1;
public class Program
{
public static async Task Main(string[] args)
{
var builder = WebAssemblyHostBuilder.CreateDefault(args);
builder.RootComponents.Add<App>("#app");
builder.RootComponents.Add<HeadOutlet>("head::after");
builder.Services.AddScoped(sp => new HttpClient { BaseAddress = new Uri(builder.HostEnvironment.BaseAddress) });
// Add this line
builder.Services.AddBlazorWebAssemblyR3();
await builder.Build().RunAsync();
}
}