From fceb8bb2beeab1de00236b500fc7cccc169efaed Mon Sep 17 00:00:00 2001 From: Jason Kuhrt Date: Tue, 25 May 2021 19:35:23 -0400 Subject: [PATCH] Apply suggestions from code review --- src/utils.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/utils.ts b/src/utils.ts index 61c2ea57..d0351b3d 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -601,8 +601,9 @@ export function graphql15InterfaceType( return type as T & { getInterfaces(): GraphQLInterfaceType[] } } -// A function that is correctly typed to get arround a TypeScript issue. -// See https://github.com/microsoft/TypeScript/issues/17002 +/** + * A specially typed version of `Array.isArray` to work around [this issue](https://github.com/microsoft/TypeScript/issues/17002). + */ export function isArray( arg: T | {} ): arg is T extends readonly any[] ? (unknown extends T ? never : readonly any[]) : any[] {