Models.ts 236 B

1234567891011
  1. import { Model, InferSchemaType } from "mongoose";
  2. import { AbcSchema } from "../models/abc";
  3. export type Schemas = {
  4. abc: AbcSchema;
  5. };
  6. export type Models = Record<
  7. keyof Schemas,
  8. Model<InferSchemaType<Schemas[keyof Schemas]>>
  9. >;