@bluelibs/runner - v6.3.1
    Preparing search index...

    Interface ITag<TConfig, TEnforceInputContract, TEnforceOutputContract, TAllowedTargets>

    Normalized runtime tag definition.

    Tags carry discovery metadata and may also encode input/output contracts.

    interface ITag<
        TConfig = void,
        TEnforceInputContract = void,
        TEnforceOutputContract = void,
        TAllowedTargets extends TagTarget | void = void,
    > {
        __allowedTagTargets?: TAllowedTargets;
        __configHasOnlyOptionalKeys: RequiredKeys<TConfig> extends never
            ? true
            : false;
        __containsContract: true;
        "[CONTRACT]": {
            config: TConfig;
            input: TEnforceInputContract;
            output: TEnforceOutputContract;
        };
        "[symbolFilePath]": string;
        "[symbolTag]": true;
        config?: TConfig;
        configSchema?: IValidationSchema<TConfig>;
        id: string;
        meta: ITagMeta;
        optional: () => IOptionalDependency<
            ITag<
                TConfig,
                TEnforceInputContract,
                TEnforceOutputContract,
                TAllowedTargets,
            >,
        >;
        startup: () => ITagStartupDependency<
            ITag<
                TConfig,
                TEnforceInputContract,
                TEnforceOutputContract,
                TAllowedTargets,
            >,
        >;
        targets?: readonly TagTarget[];
        exists(target: ITaggable | TagType[]): boolean;
        extract(target: ITaggable | TagType[]): TConfig | undefined;
        with(
            config: TConfig,
        ): ITagConfigured<
            TConfig,
            TEnforceInputContract,
            TEnforceOutputContract,
            TAllowedTargets,
        >;
    }

    Type Parameters

    • TConfig = void
    • TEnforceInputContract = void
    • TEnforceOutputContract = void
    • TAllowedTargets extends TagTarget | void = void

    Hierarchy (View Summary)

    Index

    Properties

    __allowedTagTargets?: TAllowedTargets

    Type-level helper used to constrain tag usage to allowed definition kinds.

    __configHasOnlyOptionalKeys: RequiredKeys<TConfig> extends never ? true : false

    Type-level helper used by builder overloads when tag config is fully optional.

    __containsContract: true
    "[CONTRACT]": {
        config: TConfig;
        input: TEnforceInputContract;
        output: TEnforceOutputContract;
    }
    "[symbolFilePath]": string
    "[symbolTag]": true
    config?: TConfig

    Default configuration stored on the tag definition itself.

    configSchema?: IValidationSchema<TConfig>

    Normalized validation schema for configured tag payloads.

    id: string

    Stable tag identifier.

    meta: ITagMeta

    Normalized metadata attached to this tag.

    optional: () => IOptionalDependency<
        ITag<
            TConfig,
            TEnforceInputContract,
            TEnforceOutputContract,
            TAllowedTargets,
        >,
    >

    Return an optional dependency wrapper for this tag.

    startup: () => ITagStartupDependency<
        ITag<
            TConfig,
            TEnforceInputContract,
            TEnforceOutputContract,
            TAllowedTargets,
        >,
    >

    Return a startup dependency wrapper for this tag.

    targets?: readonly TagTarget[]

    Restricts where this tag can be attached. Omit to allow any taggable definition kind.

    Methods