prorm API Reference
    Preparing search index...

    Type Alias InferAttributes<T>

    InferAttributes: {
        [K in keyof T]: T[K] extends NonAttribute<any> ? never : T[K]
    }

    InferAttributes - Extracts attribute types from a Model

    Use this type to extract the attribute types when defining a Model class. This type should be used as the first type parameter to Model.

    Type Parameters

    • T
    export class User extends Model<InferAttributes<User>, InferCreationAttributes<User>> {
    declare id: CreationOptional<number>;
    declare name: string;
    }