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

124
Vistas
How to Make Webpack Produce a JS file as-is to Use it Later for Configuration

I have a custom config JS file used to specify the REST API entry points, I need that file available in dist folder after npm run build:prod without bundling/minimization so I can edit it later in production

I tried

{
        test: /\.(js|jsx)$/,
        exclude: [
          /\bcore-js\b/,
          /\bwebpack\/buildin\b/,
          /apicalls.js$/
        ],
}

But it totally excluded it from the bundle

How can I achieve this ?

apicalls.js

 const APIURL= "https://localhost:12500/api/";
export default {

    // get all criteria in DB
    getAllCriterias: APIURL + "Criteria/getAll",
    
    //get current website user
    user: APIURL + "UserIdentity/user",
}
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