UNPKG

type-tls

Version:

type-tls 封装了与类型相关的工具,比如:获取数据的类型 或 类型名字、判断数据的类型 等

19 lines (10 loc) 424 B
<!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [type-tls](./type-tls.md) &gt; [ResolveData](./type-tls.resolvedata.md) ## ResolveData type 获取 Promise 解决的类型的值 **Signature:** ```typescript export type ResolveData<P> = P extends Promise<infer D> ? D : P; ``` ## Remarks 对于非 Promise 类型的值,返回原类型本身