// export type IModel = { // [P in keyof T]: T[P] extends Function // ? '❌此处不能定义任何方法' // : ( // T[P] extends Array // ? ( // R extends Function // ? '❌此处不能定义任何方法' // : T[P] // ) // : T[P] // IModel 性能消耗大 // ); // }; // export type IStore = { // [P in keyof T]: T[P] extends Function // ? T[P] // : ( // T[P] extends Array // ? ( // R extends Function // ? '❌此处不能定义任何方法' // : IModel // ) // : IModel // ); // }; export type IModel = { [P in keyof T]: T[P] extends Function ? '❌此处不能定义任何方法' : T[P]; }; // export type IStore = { // [P in keyof T]: T[P] extends Function // ? T[P] // : IModel; // }; export type IStore = { [P in keyof T]: T[P]; };