此时无法运行 程序报错 报错信息如下
``` bash
[Nest] 17028 - 08/03/2021, 2:57:46 PM [NestFactory] Starting Nest application...
[Nest] 17028 - 08/03/2021, 2:57:46 PM [InstanceLoader] AppModule dependencies initialized +26ms
[Nest] 17028 - 08/03/2021, 2:57:46 PM [InstanceLoader] TypeOrmModule dependencies initialized +0ms
error: [Nest] 17028 - 08/03/2021, 2:57:46 PM [ExceptionHandler] rxjs_1.lastValueFrom is not a function +1ms
error: TypeError: rxjs_1.lastValueFrom is not a function
at Function.<anonymous> (/Users/macos/Desktop/ssr/node_modules/@nestjs/typeorm/dist/typeorm-core.module.js:146:33)
at Generator.next (<anonymous>)
at /Users/macos/Desktop/ssr/node_modules/@nestjs/typeorm/dist/typeorm-core.module.js:20:71
at new Promise (<anonymous>)
at __awaiter (/Users/macos/Desktop/ssr/node_modules/@nestjs/typeorm/dist/typeorm-core.module.js:16:12)
at Function.createConnectionFactory (/Users/macos/Desktop/ssr/node_modules/@nestjs/typeorm/dist/typeorm-core.module.js:143:16)
at Function.<anonymous> (/Users/macos/Desktop/ssr/node_modules/@nestjs/typeorm/dist/typeorm-core.module.js:46:96)
at Generator.next (<anonymous>)
at /Users/macos/Desktop/ssr/node_modules/@nestjs/typeorm/dist/typeorm-core.module.js:20:71
at new Promise (<anonymous>)
安装依赖
引入配置 src/app.module.ts
@Module({ imports: [ TypeOrmModule.forRoot({ type: 'mysql', host: 'localhost', port: 3306, username: 'root', password: 'root', database: 'test', entities: [], synchronize: true }), DetailModule, indexModule ] }) export class AppModule {}
是不允许这样使用还是我的配置有问题。