UNPKG

@types/levn

Version:
44 lines (33 loc) 1.2 kB
# Installation > `npm install --save @types/levn` # Summary This package contains type definitions for levn (https://github.com/gkz/levn). # Details Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/levn. ## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/levn/index.d.ts) ````ts import { CustomType, ParsedType, ParsedTypeData } from "type-check"; export interface CastableCustomType extends CustomType { cast: (input: unknown) => ParsedTypeData; } export interface ParseOptions { customTypes?: Record<string, CastableCustomType> | undefined; explicit?: boolean | undefined; } export function parse( type: string, string: string, options?: ParseOptions, ): unknown; export function parsedTypeParse( parsedType: ParsedType, input: string, options?: ParseOptions, ): unknown; export const VERSION: string; ```` ### Additional Details * Last updated: Fri, 06 Sep 2024 21:07:35 GMT * Dependencies: [@types/type-check](https://npmjs.com/package/@types/type-check) # Credits These definitions were written by [Josh Goldberg](https://github.com/JoshuaKGoldberg).