Setu-TS
    Preparing search index...

    Function validatedStateKey

    • Builds the ctx.state key under which the validated value for a target is stored — the cross-package wire format between the writer (validation-plugin's middleware) and any reader (e.g. decorator-plugin's parameter resolvers). Both sides import this helper so the key can never drift between the package that writes it and the one that reads it back.

      Parameters

      Returns string

      The state key — `validation-plugin:validated-${target}`

      ctx.state.set(validatedStateKey('body'), parsedValue);
      const validated = ctx.state.get(validatedStateKey('body'));

      0.2.0