Hi, I have this issue: my database doesn't restart when I make changes to its schema and relaunch the app. I have the synchronize option of the TypeOrmModule.forRootAsync activated, but nothing happens
My config code:
ConfigModule.forRoot({ isGlobal: true }), //load the .env file globally, to use it only write configService.get(‘VariableName’)
TypeOrmModule.forRootAsync({
imports: [ConfigModule],
useFactory: (configService: ConfigService) => ({
type: 'postgres',
host: configService.get('DB_HOST'),
port: +configService.get<number>('DB_PORT'),
username: configService.get('DB_USERNAME'),
password: configService.get('DB_PASSWORD'),
database: configService.get('DB_NAME'),
entities: [],
synchronize: true,
autoLoadEntities: true,
}),
inject: [ConfigService],
}), ```