xInjection - v3.0.0
    Preparing search index...

    Interface IDynamicModuleDefinition

    interface IDynamicModuleDefinition {
        subscribe: (
            callback: SignalCallback<DefinitionEvent>,
            invokeImmediately?: boolean,
        ) => () => void;
        addImport(
            moduleOrBlueprint: ModuleOrBlueprint,
            addToExports?: boolean,
        ): void;
        addProvider<T>(
            provider: DependencyProvider<T>,
            addToExports?: boolean,
        ): void;
        removeFromExports(exportDefinition: ExportDefinition): boolean;
        removeImport(moduleOrId: IProviderModule | ModuleIdentifier): boolean;
        removeProvider<T>(
            providerOrIdentifier:
                | string
                | symbol
                | Function
                | Class<T>
                | ProviderClassToken<T>
                | ProviderValueToken<T>
                | ProviderFactoryToken<T>,
        ): boolean;
    }

    Implemented by

    Index

    Properties

    subscribe: (
        callback: SignalCallback<DefinitionEvent>,
        invokeImmediately?: boolean,
    ) => () => void

    Can be used to subscribe in real-time to the definition changes.

    Type declaration

      • (
            callback: SignalCallback<DefinitionEvent>,
            invokeImmediately?: boolean,
        ): () => void
      • Can be used to subscribe to the emitted values of this Signal.

        Parameters

        • callback: SignalCallback<DefinitionEvent>

          The callback which will be invoked when a new value is emitted.

        • OptionalinvokeImmediately: boolean

          When set to true it'll invoke the provided callback immediately with the latest value available. (defaults to false)

        Returns () => void

    Methods