effex-monorepo
    Preparing search index...

    Interface WhenConfig<E1, R1, E2, R2>

    Configuration for the when control flow (DOM-specific with animation support).

    interface WhenConfig<E1 = never, R1 = never, E2 = never, R2 = never> {
        animate?: AnimationOptions;
        container?: () => Element<HTMLElement | SVGElement, never, never>;
        onFalse: () => Element<HTMLElement | SVGElement, E2, R2>;
        onTrue: () => Element<HTMLElement | SVGElement, E1, R1>;
    }

    Type Parameters

    • E1 = never
    • R1 = never
    • E2 = never
    • R2 = never
    Index

    Properties

    Optional animation configuration

    container?: () => Element<HTMLElement | SVGElement, never, never>

    Optional custom container element. If not provided, defaults to a div with display: contents.

    onFalse: () => Element<HTMLElement | SVGElement, E2, R2>

    Element to render when condition is false

    onTrue: () => Element<HTMLElement | SVGElement, E1, R1>

    Element to render when condition is true