This site provides a machine-readable index at /llms.txt.

Skip to main content Skip to navigation

BlogSiteServiceExtensions Pennington.BlogSite

DI extension methods for registering and running the BlogSite template.

Methods

AddBlogSite

#
public static IServiceCollection AddBlogSite(this IServiceCollection services,
    Func<BlogSiteOptions> configureOptions);

Registers BlogSite services with the provided options.

Parameters

services IServiceCollection
configureOptions Func<BlogSiteOptions>

Returns

IServiceCollection

RunBlogSiteAsync

#
public static async Task RunBlogSiteAsync(this WebApplication app, string[] args);

Runs the BlogSite: either serves the app or performs a static build, based on command-line args.

Parameters

app WebApplication
args string[]

Returns

Task

UseBlogSite

#
public static WebApplication UseBlogSite(this WebApplication app);

Wires BlogSite middleware, Razor components, and RSS endpoint into the request pipeline.

Parameters

app WebApplication

Returns

WebApplication

Pennington.BlogSite.BlogSiteServiceExtensions

namespace Pennington.BlogSite;

/// DI extension methods for registering and running the BlogSite template.
public class BlogSiteServiceExtensions
{
    /// Registers BlogSite services with the provided options.
    
public static IServiceCollection AddBlogSite(this IServiceCollection services,
    Func<BlogSiteOptions> configureOptions);
/// Runs the BlogSite: either serves the app or performs a static build, based on command-line args.
public static async Task RunBlogSiteAsync(this WebApplication app, string[] args);
/// Wires BlogSite middleware, Razor components, and RSS endpoint into the request pipeline.
public static WebApplication UseBlogSite(this WebApplication app);
}