turbodombuilder - v0.9.22
    Preparing search index...

    Function interactor

    • Function

      Parameters

      • Optionalname: string

        The key name of the interactor in the MVC instance (if any). By default, it is inferred from the name of the field. If the field is named somethingInteractor, the key name will be something.

      Returns (_unused: unknown, context: ClassFieldDecoratorContext) => void

      interactor

      Stage-3 field decorator for MVC structure. It reduces code by turning the decorated field into a fetched interactor.

      @interactor() protected textInteractor: TurboInteractor;
      

      Is equivalent to:

      protected get textInteractor(): TurboInteractor {
      if (this.mvc instanceof Mvc) return this.mvc.getInteractor("text");
      if (typeof this.getInteractor === "function") return this.getInteractor("text");
      }