From 16c016e8b1d5ca46343d3363f9a49e24c5d7c944 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 12 May 2021 14:09:04 +0200 Subject: Stricter models typing --- shared/core-utils/miscs/types.ts | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'shared') diff --git a/shared/core-utils/miscs/types.ts b/shared/core-utils/miscs/types.ts index bb64dc830..bd2a97b98 100644 --- a/shared/core-utils/miscs/types.ts +++ b/shared/core-utils/miscs/types.ts @@ -6,6 +6,10 @@ export type FunctionPropertyNames = { export type FunctionProperties = Pick> +export type AttributesOnly = { + [K in keyof T]: T[K] extends Function ? never : T[K] +} + export type PickWith = { [P in KT]: T[P] extends V ? V : never } -- cgit v1.2.3