net9 Update
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
using Blazorise;
|
||||
using Blazorise.Icons.Material;
|
||||
using Blazorise.Material;
|
||||
using FoodsharingSiegen.Server;
|
||||
using FoodsharingSiegen.Server.Auth;
|
||||
using FoodsharingSiegen.Server.Data;
|
||||
using FoodsharingSiegen.Server.Data.Service;
|
||||
@@ -9,14 +10,15 @@ using Microsoft.AspNetCore.Components.Authorization;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
builder.LoadAppSettings();
|
||||
|
||||
builder.WebHost.UseUrls("http://+:8700");
|
||||
|
||||
// Add services to the container.
|
||||
builder.Services.AddRazorPages();
|
||||
builder.Services.AddServerSideBlazor();
|
||||
builder.Services.AddSingleton<WeatherForecastService>();
|
||||
builder.Services.AddDbContextFactory<FsContext>(opt =>
|
||||
opt.UseSqlite($"Data Source=app.db"));
|
||||
builder.AddDatabaseContext();
|
||||
|
||||
// DI
|
||||
builder.Services.AddScoped<LocalStorageService>();
|
||||
@@ -28,8 +30,13 @@ builder.Services.AddScoped<AuthService>();
|
||||
builder.Services.AddScoped<UserService>();
|
||||
builder.Services.AddScoped<ProspectService>();
|
||||
|
||||
|
||||
builder.Services.AddBlazorise( options => { options.Immediate = true; }).AddMaterialProviders().AddMaterialIcons();
|
||||
builder.Services
|
||||
.AddBlazorise( options =>
|
||||
{
|
||||
options.Immediate = true;
|
||||
} )
|
||||
.AddMaterialProviders()
|
||||
.AddMaterialIcons();
|
||||
|
||||
var app = builder.Build();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user