This documentation is also published as Markdown for efficient machine reading: the whole site is indexed at /llms.txt, and every page has a clean Markdown copy under /_llms/. These are generated from the same source and cost far fewer tokens to read than this rendered HTML.

Skip to main content Skip to navigation

PenningtonBookExtensions Pennington.Book

Dependency injection extensions for the Pennington PDF book feature.

Methods

AddPenningtonBook

#
public static IServiceCollection AddPenningtonBook(IServiceCollection services, Action<BookOptions> configure = null)

Adds PDF book generation: a per-locale book per BookDefinition (or one whole-site book when none are configured), served on demand at /pdf/{slug}.pdf in dev and emitted into the static build. Registers an IDownloadLinkProvider a host's chrome can advertise.

Parameters

services IServiceCollection
configure Action<BookOptions>

Returns

IServiceCollection

Pennington.Book.PenningtonBookExtensions

namespace Pennington.Book;

/// Dependency injection extensions for the Pennington PDF book feature.
public class PenningtonBookExtensions
{
    /// Adds PDF book generation: a per-locale book per BookDefinition (or one whole-site book when none are configured), served on demand at /pdf/{slug}.pdf in dev and emitted into the static build. Registers an IDownloadLinkProvider a host's chrome can advertise.
    
public static IServiceCollection AddPenningtonBook(IServiceCollection services, Action<BookOptions> configure = null)
; }