Remove Blazor

This commit is contained in:
Jonathan Jenne
2023-11-08 14:52:14 +01:00
parent ba1d6acfa4
commit 2c936c2629
1614 changed files with 75165 additions and 14959 deletions

View File

@@ -1,6 +1,4 @@
using EnvelopeGenerator.Web.Data;
using Microsoft.AspNetCore.Components;
using Microsoft.AspNetCore.Components.Web;
using EnvelopeGenerator.Web.Services;
namespace EnvelopeGenerator.Web
{
@@ -10,29 +8,34 @@ namespace EnvelopeGenerator.Web
{
var builder = WebApplication.CreateBuilder(args);
// Add base services
builder.Services.AddSingleton<LoggingService>();
builder.Services.AddTransient<DatabaseService>();
// Add higher order services
builder.Services.AddSingleton<EnvelopeService>();
// Add services to the container.
builder.Services.AddRazorPages();
builder.Services.AddServerSideBlazor();
builder.Services.AddSingleton<WeatherForecastService>();
builder.Services.AddControllersWithViews();
var app = builder.Build();
// Configure the HTTP request pipeline.
if (!app.Environment.IsDevelopment())
{
app.UseExceptionHandler("/Error");
app.UseExceptionHandler("/Home/Error");
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
app.UseHsts();
}
app.UseHttpsRedirection();
app.UseStaticFiles();
app.UseRouting();
app.MapBlazorHub();
app.MapFallbackToPage("/_Host");
app.UseAuthorization();
app.MapControllers();
app.Run();
}