How to use the @esfx/internal-guards.isPropertyKey function in @esfx/internal-guards

To help you get started, we’ve selected a few @esfx/internal-guards examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github esfx / esfx / packages / reflect-metadata-compat / src / index.ts View on Github external
function isMemberOverload(args: Overloads): args is readonly [object, PropertyKey] {
    if (args.length >= 2 && isObject(args[0]) && isPropertyKey(args[1]) && (args.length === 2 || !isDefined(args[2]) || isObject(args[2]))) return true;
    return false;
}
github esfx / esfx / packages / reflect-metadata-compat / src / index.ts View on Github external
function isDecorateMemberOverload(args: DecorateOverloads): args is readonly [(PropertyDecorator | MethodDecorator)[], object, PropertyKey, PropertyDescriptor?] {
        if (args.length >= 3 && Array.isArray(args[0]) && isObject(args[1]) && isPropertyKey(args[2]) && (isObject(args[3]) || !isDefined(args[3]))) return true;
        return false;
    }
github esfx / esfx / packages / reflect-metadata-compat / src / index.ts View on Github external
function isParameterOverload(args: Overloads): args is readonly [object, PropertyKey, number] {
    if (args.length >= 3 && isObject(args[0]) && isPropertyKey(args[1]) && typeof args[2] === "number") return true;
    return false;
}

@esfx/internal-guards

This package provides internal utilities for @esfx and is not intended for use in user-code.

Apache-2.0
Latest version published 2 years ago

Package Health Score

48 / 100
Full package analysis

Similar packages