fix(nuxt3): correct KeysOf type (#737)

This commit is contained in:
Daniel Roe 2021-10-12 09:52:09 +01:00 committed by GitHub
parent 2291a9dd9f
commit d1e0af928e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -5,7 +5,7 @@ import { NuxtApp, useNuxtApp } from '#app'
export type _Transform<Input=any, Output=any> = (input: Input) => Output
export type PickFrom<T, K extends Array<string>> = T extends Record<string, any> ? Pick<T, K[number]> : T
export type KeysOf<T> = Array<keyof T extends string ? T : string>
export type KeysOf<T> = Array<keyof T extends string ? keyof T : string>
export type KeyOfRes<Transform extends _Transform> = KeysOf<ReturnType<Transform>>
export interface AsyncDataOptions<