Skip to content

ExactKeys<Type, Keys>

A type that represents the keys of an object as strings and asserts that all keys are present in a list of keys.

Import:

import type { ExactKeys } from 'obsidian-dev-utils/type';

Signature:

export type ExactKeys<Type extends object, Keys extends readonly string[]>

Signature:

type ExactKeys<Type, Keys> = ExactMembers<StringKeys<Type>, Keys>

Type: ExactMembers<StringKeys<Type>, Keys>