Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

223
Vistas
Nx workspace + Nest.js: separate bundle for each library

My problem is that whenever I run nx build api I get a single main.js which includes everything in my monorepo. What I want is my libraries having their own .js bundles. It can be clearly seen here angular-spotify . If you compile the project, you will see that each library has own bundle file. Here is what it looks like: example dist folder.

I also made an example repo showing my problem here: example repo. As you can see, all I have is main.js file, despite having also shared module, which is supposed to have its own bundle file.

My goal ultimately is being able to use typeorm migration feature with typescript. My typeorm entities are TS files which located in a separate lib, but migration works only with JS entities. Thus I need to compile my TS entities (which include imports from other libs) to JS files and specify folder in the dist in ormconfig.json like this dist/entities/*.js. But it is not possible if I only have bare main.js as output file.

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda