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

150
Vistas
How to translate this esbuild CLI sentence to JS file

I managed to construct this esbuild CLI sentence, but I am struggling to transform it to a JS build file:

esbuild out1=src/out1.ts out2=src/out2.ts out3=src/out3.ts --bundle --outdir=dist --watch --minify

This takes 3 different files and bundles it to 3 different files, that is exactly what I want. But now I want to add more bundle rules, and I don't want to keeping adding to this and have a separate file for the bundle.

Someone can point me to the docs or giving some hints on how to achieve it?

about 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

It was the silliest thing. Just add them as an entryPoints and add the left ones to the esbuild.build config:

import { build } from 'esbuild';

build({
  entryPoints: ['src/out1.ts', "src/out2.ts", "src/out3.ts"],
  outdir: 'dist',
  minify: true,
  bundle: true,
  watch: true,
  target: 'es2020',
}).catch(error => process.exit(1));
about 4 years ago · Santiago Trujillo Denunciar
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