Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

原有项目由cjs改为esm后typeorm的entity里相互关联实体会报错 #3263

Open
ndpay opened this issue Sep 19, 2023 · 1 comment
Open

Comments

@ndpay
Copy link

ndpay commented Sep 19, 2023

  • Node Version: 18
  • Midway Version(Decorator/Core): 3.12.0
  • Component Name/Version:
  • Platform: Mac系统
  • Mini Showcase Repository:

编译watch的时候报错如下:

file:///Users/develop/www/web/dzpp/dzpp_server/dist/modules/hotel/entity/hotel.images.js:38
__metadata("design:type", HotelEntity)
^

ReferenceError: Cannot access 'HotelEntity' before initialization
at file:///Users/develop/www/web/dzpp/dzpp_server/dist/modules/hotel/entity/hotel.images.js:38:31
at ModuleJob.run (node:internal/modules/esm/module_job:194:25)

在cjs没有报错!

@rojer95
Copy link

rojer95 commented Nov 7, 2023

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants