Skip to content

shouldSkip

Source Code | Documentation

See also: skippable addSkip

Util to detect if a hook should be skipped

Checks the params.skipHooks array for the hook name, type, or 'all'.

ts
  import { 
shouldSkip
} from 'feathers-utils/predicates';

Type declaration

ts
/**
 * Util to detect if a hook should be skipped
 *
 * Checks the `params.skipHooks` array for the hook name, type, or 'all'.
 */
export declare const shouldSkip: <H extends HookContext = HookContext>(
  hookName: SkipHookName,
) => (context: H) => boolean
ArgumentTypeDescription
hookNameSkipHookName

Released under the MIT License.