Setu-TS
    Preparing search index...

    Variable servicesContextConst

    servicesContext: RouterContextKey<IServiceRegistry | null> = ...

    Key holding the kernel IServiceRegistry for the current request.

    Always set by the plugin, so context.get(servicesContext) never returns the null default on a request served through the SSR catch-all. The | null in the type exists only because the key needs a default at all — React Router's get() throws for an unset key that has none.

    import { servicesContext } from '@setu-ts/react-router-plugin';
    import { CAPABILITIES, type ILogger } from '@setu-ts/common';

    export async function loader({ context }: Route.LoaderArgs) {
    const services = context.get(servicesContext);
    services?.get<ILogger>(CAPABILITIES.LOGGER).info('ssr loader');
    return { ok: true };
    }

    0.2.0