Function getModelForClass

  • Build a Model From a Class

    Type Parameters

    Parameters

    • cl: U

      The Class to build a Model from

    • Optional options: IModelOptions

      Overwrite Options, like for naming or general SchemaOptions the class gets compiled with

      Optional

    Returns ReturnModelType<U, QueryHelpers>

    The finished Model

    Example

    class ClassName {}

    const NameModel = getModelForClass(ClassName);

Generated using TypeDoc