Skip to content

hasPatchToken

Checks if a function has a specific patch token.

Import:

import { hasPatchToken } from 'obsidian-dev-utils/obsidian/components/monkey-around-component';

Signature:

function hasPatchToken(fn: GenericFunction, patchToken: symbol): boolean

Parameters:

ParameterTypeDescription
fnGenericFunctionThe function to check.
patchTokensymbolThe patch token to check for.

Returns: boolean — Whether the function has the patch token.