effex-monorepo
    Preparing search index...

    Type Alias PermissiveChildren<E, R>

    PermissiveChildren: ReadonlyArray<ChildInput<E, R>>

    Variadic-rest type for wrappers that only forward children without mixing in wrapper-owned elements:

    const Link = <E = never, R = never>(
    props: LinkProps,
    ...children: PermissiveChildren<E, R>
    ): Element<HTMLAnchorElement, E, R> =>
    $.a({ href: props.href }, children);

    Uses ChildInput — callers may pass an array as a single argument (Link(props, [a, b])) as well as spread or variadic. In exchange, the wrapper cannot interleave its own children with the forwarded ones in the same primitive call (it must forward children as the sole child argument).

    Type Parameters

    • E = never
    • R = never