diff --git a/types/sequelize/index.d.ts b/types/sequelize/index.d.ts index b7bf448aed..dae8b3475c 100644 --- a/types/sequelize/index.d.ts +++ b/types/sequelize/index.d.ts @@ -7,6 +7,7 @@ // Patsakol Tangjitcharoenchai // Sebastien Bramille // Nick Mueller +// Philippe D'Alva // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.3 @@ -1329,7 +1330,13 @@ declare namespace sequelize { * A string or a data type to represent the identifier in the table */ keyType?: DataTypeAbstract; - + /** + * A string to represent the name of the field to use as the key for an 1 to many association in the source table. + * + * @see http://docs.sequelizejs.com/class/lib/model.js~Model.html#static-method-hasMany + * @see https://github.com/sequelize/sequelize/blob/b4fd46426db9cdbb97074bea121203d565e4195d/lib/associations/has-many.js#L81 + */ + sourceKey?: string; } /**