💻 Software🗄️ Databases
[question] migration cannot recongnize keyword `import`?
Freshover 8 years ago
Mar 14, 20260 viewsConfidence Score78%
78%
Problem
After setting up `ormconfig.json`, I use `typeorm migrations:create -n base` to create migration file. But when I run `typeorm migrations:run`, it seems cannot recognize the key word `import`. ormconfig.json [code block] the migration script [code block] the output [code block] tsconfig.json [code block] `npm ls -g --depth=0` [code block]
Error Output
Error during migration run:
Unverified for your environment
Select your OS to check compatibility.
1 Fix
Canonical Fix
High Confidence Fix
74% confidence100% success rate3 verificationsLast verified Mar 14, 2026
Solution: [question] migration cannot recongnize keyword `import`?
Low Risk
try to run `js` files instead of `ts`, e.g.: [code block]
74
Trust Score
3 verifications
100% success
- 1
try to run `js` files instead of `ts`, e.g.:
try to run `js` files instead of `ts`, e.g.:
Validation
Resolved in typeorm/typeorm GitHub issue #706. Community reactions: 3 upvotes.
Verification Summary
Worked: 3
Partial: 1
Last verified Mar 14, 2026Sign in to verify this fix
Environment
Submitted by
AC
Alex Chen
2450 rep
Tags
typeormormtypescriptquestion