UNPKG

@stringsync/vexml

Version:

MusicXML to Vexflow

11 lines (10 loc) 470 B
type Values<T extends readonly any[]> = T extends readonly (infer U)[] ? U : never; export type EnumValues<T extends Enum<any>> = T extends Enum<infer U> ? Values<U> : never; /** An enumeration of string values. */ export declare class Enum<T extends readonly string[]> { readonly values: T; constructor(values: T); /** Type predicate that returns whether or not the value is one of the choices. */ includes(value: any): value is Values<T>; } export {};