Skip to main content
Module

x/typeorm/src/index.ts>MongoEntityManager#createCollectionIndexes

Forked from https://github.com/typeorm/typeorm
Latest
method MongoEntityManager.prototype.createCollectionIndexes
Re-export
import { MongoEntityManager } from "https://deno.land/x/typeorm@v0.2.23-rc10/src/index.ts";

Creates multiple indexes in the collection, this method is only supported for MongoDB 2.6 or higher. Earlier version of MongoDB will throw a command not supported error. Index specifications are defined at http://docs.mongodb.org/manual/reference/command/createIndexes/.

Parameters

entityClassOrName: ObjectType<Entity> | EntitySchema<Entity> | string
indexSpecs: ObjectLiteral[]

Returns

Promise<void>