2.0.5 • Published 9 months ago

@golee/migrations-nest v2.0.5

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
9 months ago

Migrations

Below an example of how to configure two migrations scripts (order matters) and their dependencies.

MigrationsModule.forRoot({
    mongoDbConnectionName: 'monogoose_connection_name', // If not specified will use the default connection
	scripts: [
		{
			provide: 'MigrationExample1',
			useFactory: (repo: Repo) => {
				return new MigrationExample1(repo);
			},
			inject: [Repo],
		},
		{
			provide: 'MigrationExample2',
			useFactory: (providerx: ProviderX) => {
				return new MigrateDeletedGeorgianClubs(providerx);
			},
			inject: [ProviderX],
		},
	],
	imports: [
		XModule,
		MongooseModule.forFeature([{ name: 'XModel', schema: XModel, collection: 'xmodels' }]),
	],
})
2.0.3

9 months ago

2.0.2

9 months ago

2.0.5

9 months ago

2.0.4

9 months ago

2.0.1

9 months ago

1.0.3

10 months ago

1.0.2

10 months ago

1.0.1

1 year ago

1.0.0

1 year ago

0.8.2

1 year ago

0.8.1

2 years ago

0.8.0

2 years ago

0.7.2

3 years ago

0.7.1

3 years ago

0.7.4

3 years ago

0.7.3

3 years ago

0.5.0

3 years ago

0.4.0

3 years ago

0.7.0

3 years ago

0.6.0

3 years ago

0.3.1

3 years ago

0.3.0

3 years ago

0.2.2

3 years ago

0.2.1

3 years ago

0.2.0

3 years ago

0.1.3

3 years ago

0.1.2

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago