Debugger attached.
Debugger attached.
/usr/local/lib/node_modules/ts-node/dist-raw/node-internal-modules-esm-resolve.js:757
throw new ERR_MODULE_NOT_FOUND(packageName, fileURLToPath(base));
^
CustomError: Cannot find package 'typeorm' imported from /home/ec2-user/tutorial/node_modules/@adminjs/typeorm/lib/Resource.js
at packageResolve (/usr/local/lib/node_modules/ts-node/dist-raw/node-internal-modules-esm-resolve.js:757:9)
at moduleResolve (/usr/local/lib/node_modules/ts-node/dist-raw/node-internal-modules-esm-resolve.js:798:18)
at Object.defaultResolve (/usr/local/lib/node_modules/ts-node/dist-raw/node-internal-modules-esm-resolve.js:912:11)
at /usr/local/lib/node_modules/ts-node/src/esm.ts:218:35
at entrypointFallback (/usr/local/lib/node_modules/ts-node/src/esm.ts:168:34)
at /usr/local/lib/node_modules/ts-node/src/esm.ts:217:14
at addShortCircuitFlag (/usr/local/lib/node_modules/ts-node/src/esm.ts:409:21)
at resolve (/usr/local/lib/node_modules/ts-node/src/esm.ts:197:12)
at resolve (/usr/local/lib/node_modules/ts-node/src/child/child-loader.ts:15:39)
at nextResolve (node:internal/modules/esm/loader:163:28)
Waiting for the debugger to disconnect...
### Relevant code that's giving you issues
_No response_
Contact Details
No response
What happened?
List what you are trying to do?
Try to run the app,
ts-node --esm app.ts
Bug prevalence
Always
AdminJS dependencies version
{ "name": "api-exp", "version": "0.0.0", "type": "module", "private": true, "scripts": { "start": "ts-node ./bin/www" }, "dependencies": { "@adminjs/express": "^6.0.0", "@adminjs/mongoose": "^4.0.0", "@adminjs/typeorm": "^5.0.0", "adminjs": "^7.2.1", "cookie-parser": "~1.4.4", "debug": "~2.6.9", "express": "^4.18.2", "express-formidable": "^1.2.0", "express-session": "^1.17.3", "http-errors": "~1.6.3", "jade": "~1.11.0", "mongoose": "^7.5.0", "morgan": "~1.9.1", "tslib": "^2.6.2" }, "devDependencies": { "@adminjs/typeorm": "^5.0.0", "@tsconfig/recommended": "^1.0.2", "@types/express": "^4.17.17" } }
What browsers do you see the problem on?
Chrome
Relevant log output