Add project files.
This commit is contained in:
18
BlazorSyncfusionCrm/Client/Program.cs
Normal file
18
BlazorSyncfusionCrm/Client/Program.cs
Normal file
@ -0,0 +1,18 @@
|
||||
using BlazorSyncfusionCrm.Client;
|
||||
using Microsoft.AspNetCore.Components.Web;
|
||||
using Microsoft.AspNetCore.Components.WebAssembly.Hosting;
|
||||
using Syncfusion.Blazor;
|
||||
|
||||
var builder = WebAssemblyHostBuilder.CreateDefault(args);
|
||||
builder.RootComponents.Add<App>("#app");
|
||||
builder.RootComponents.Add<HeadOutlet>("head::after");
|
||||
|
||||
builder.Services.AddHttpClient("BlazorSyncfusionCrm.ServerAPI", client => client.BaseAddress = new Uri(builder.HostEnvironment.BaseAddress));
|
||||
|
||||
// Supply HttpClient instances that include access tokens when making requests to the server project
|
||||
builder.Services.AddScoped(sp => sp.GetRequiredService<IHttpClientFactory>().CreateClient("BlazorSyncfusionCrm.ServerAPI"));
|
||||
builder.Services.AddSyncfusionBlazor();
|
||||
|
||||
Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense("MTcyMTQ0NkAzMjMxMmUzMTJlMzMzNVNvVmlFLy9zUk5TTTlURGZIeTRCelpRR2FTQ1NXTXRrSGpNcVJKMzRES1E9");
|
||||
|
||||
await builder.Build().RunAsync();
|
||||
Reference in New Issue
Block a user