You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At the moment, there's no clean example that could help build a scalable application in the monorepo with @nrwl/nest as backend. Many sources provide quite limited information and it breaks once the API grows. There are some challenges:
with nestjs all Entites are combined with relative path __dirname + '/../*/.entity{.ts,.js}' and it's not possible in the monorepo, as soon as it breaks the border of the module => Error: 'Cannon use import statement outside a module';
every Entity should be directly imported in the different modules and it creates quickly A circular dependency between modules;
to avoid A circular dependency that throws an unresolved error, all entities should be kept in one big module;
classes, imported from the different modules, don't always properly instantiated in the decorators.
I created some repo with the mentioned challenges:
Imho, I want to believe that it would be nice to have an easy but scalable example, something like auth-users-posts-comments with all dungeons of @NxDevTools & @nestframework.
The text was updated successfully, but these errors were encountered:
At the moment, there's no clean example that could help build a scalable application in the monorepo with @nrwl/nest as backend. Many sources provide quite limited information and it breaks once the API grows. There are some challenges:
with nestjs all Entites are combined with relative path
__dirname + '/../*/.entity{.ts,.js}'
and it's not possible in the monorepo, as soon as it breaks the border of the module =>Error: 'Cannon use import statement outside a module'
;every Entity should be directly imported in the different modules and it creates quickly
A circular dependency between modules
;to avoid
A circular dependency
that throws an unresolved error, all entities should be kept in one big module;classes, imported from the different modules, don't always properly instantiated in the decorators.
I created some repo with the mentioned challenges:
1 - 2: https://github.com/sketchnotes/nx-nestjs
3 - 4: https://github.com/sketchnotes/nx-nestjs-JwtAuthGuard/
Imho, I want to believe that it would be nice to have an easy but scalable example, something like auth-users-posts-comments with all dungeons of @NxDevTools & @nestframework.
The text was updated successfully, but these errors were encountered: