Documentation
    Preparing search index...

    Function profile

    • Implements '@profile' decorator.

      Parameters

      Returns (
          target: any,
          methodName: string,
          descriptor: TypedPropertyDescriptor<(...args: any[]) => any>,
      ) => void

      ~~~typescript
      import { profile } from '@imqueue/core';

      class MyClass {

      @profile(true) // forced profiling
      public myMethod() {
      // ...
      }

      @profile() // profiling happened only depending on env DEBUG flag
      private innerMethod() {
      // ...
      }
      }
      ~~~