Signed-off-by: Johan Haals <johan.haals@gmail.com>
This commit is contained in:
Johan Haals
2021-09-10 10:11:27 +02:00
parent 608f067ea1
commit c6c5a92e92
2 changed files with 4 additions and 5 deletions
+3 -3
View File
@@ -57,9 +57,9 @@ export default class TypeLocator {
* Find exported instances and return values from calls using the types
* provided in the lookup table.
*/
findExportedInstances<T extends string>(
typeLookupTable: { [key in T]: ts.Type },
): { [key in T]: ExportedInstance[] } {
findExportedInstances<T extends string>(typeLookupTable: {
[key in T]: ts.Type;
}): { [key in T]: ExportedInstance[] } {
const docMap = new Map<ts.Type, ExportedInstance[]>();
for (const type of Object.values<ts.Type>(typeLookupTable)) {
docMap.set(type, []);
+1 -2
View File
@@ -27,8 +27,7 @@ export type Exact<T extends { [key: string]: unknown }> = {
export type Omit<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;
export type RequireFields<T, K extends keyof T> = {
[X in Exclude<keyof T, K>]?: T[X];
} &
{ [P in K]-?: NonNullable<T[P]> };
} & { [P in K]-?: NonNullable<T[P]> };
/** All built-in and custom scalars, mapped to their actual values */
export type Scalars = {
ID: string;