quando digito typeorm-ts-node-esm -d src/db/data-source-cli.ts migration:show ele me dá esse erro
Error during migration show:
Error: Unable to open file: "D:\Prog\nestjs-rest-loja-main\src\db\data-source-cli.ts". Cannot use import statement outside a module
at CommandUtils.loadDataSource (C:\Users\pedro\AppData\Roaming\npm\node_modules\typeorm\commands\CommandUtils.js:22:19)
at async Object.handler (C:\Users\pedro\AppData\Roaming\npm\node_modules\typeorm\commands\MigrationShowCommand.js:27:26)
e quando eu digito typeorm-ts-node-esm --dataSource dist/db/data-source.js migration:show ele me dá esse erro
Error during migration show:
Error: Unable to open file: "D:\Prog\nestjs-rest-loja-main\dist\db\data-source.js". Cannot find module 'D:\Prog\nestjs-rest-loja-main\dist\db\data-source.js'
Require stack:
- C:\Users\pedro\AppData\Roaming\npm\node_modules\typeorm\util\ImportUtils.js
- C:\Users\pedro\AppData\Roaming\npm\node_modules\typeorm\commands\CommandUtils.js
- C:\Users\pedro\AppData\Roaming\npm\node_modules\typeorm\commands\SchemaSyncCommand.js
- C:\Users\pedro\AppData\Roaming\npm\node_modules\typeorm\cli.js
- C:\Users\pedro\AppData\Roaming\npm\node_modules\typeorm\cli-ts-node-esm.js
at CommandUtils.loadDataSource (C:\Users\pedro\AppData\Roaming\npm\node_modules\typeorm\commands\CommandUtils.js:22:19)
at async Object.handler (C:\Users\pedro\AppData\Roaming\npm\node_modules\typeorm\commands\MigrationShowCommand.js:27:26)
estou usando o NODE LTS 20.10, o typeorm 0.3.17 e estou usando o windows 11