Skip to content

stashBefore

Source Code | Documentation

Stash current value of record, usually before mutating it. Performs a get call.

ts
  import { 
stashBefore
} from 'feathers-utils/hooks';

Type declaration

ts
/**
 * Stash current value of record, usually before mutating it. Performs a get call.
 *
 * @see https://utils.feathersjs.com/hooks/stash-before.html
 */
export declare function stashBefore<H extends HookContext = HookContext>(
  fieldName?: string,
): (context: H, next?: NextFunction) => Promise<any>
ArgumentTypeDescription
fieldNamestring
typemethodsmulti
before, aroundget, update, patch, removeyes

Released under the MIT License.