seneca icon indicating copy to clipboard operation
seneca copied to clipboard

Plugin namespace conflict

Open vitorclelis96 opened this issue 3 years ago • 0 comments

When using the debug plugin, it's namespace will conflict with seneca definition types and it's configuration parameters will get inject with new parameters.

Seneca debug namespace:

debug?: {
      // Throw (some) errors from seneca.act.
      fragile?:    boolean | undefined;
      // Fatal errors ... aren't fatal. Not for production!
      undead?:     boolean | undefined;
      // Print debug info to console
      print?: {
          // Print options. Best used via --seneca.print.options.
          options?: boolean | undefined;
      } | undefined;
      // Trace action caller and place in args.caller$.
      act_caller?: boolean | undefined;
      // Shorten all identifiers to 2 characters.
      short_logs?: boolean | undefined;
      // Record and log callpoints (calling code locations).
      callpoint?: boolean | undefined;
  } | undefined;

Those parameters will get injected in the debug config parameters if you boot it like this:

seneca.use('debug', { ...myParams })

vitorclelis96 avatar Dec 21 '22 11:12 vitorclelis96