Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

170
Visualizações
Webpack building assets with invalid JS syntax

For some reason webpack suddenly started building assets with invalid syntax in our pipeline. Two examples of cases when this happens:

  1. First case

Expected output in chunk:

  ...
  58521: function(t, n, r) {
    var e = r(15387), o = r(19220), u = r(18882), c = r(55231), i = r(84307), f = Math.max;
    t.exports = function(t, n, r, a) {
      ... // valid function content
    };
  }
  ...
  84307: function(t, n, r) {
    var e = r(80006), o = r(28327);
    t.exports = function(t) {
      ... // valid function content
    };
  }

Actual output:

  ...
  58521: function(t, n, r) {
    var e = r(15387), o = r(19220), u = r(18882), c = r(55231), i = r(11bc6), f = Math.max; // SyntaxError: Invalid or unexpected token
    t.exports = function(t, n, r, a) {
      ... // valid function content
    };
  },
  ...
  11bc6: function(t, n, r) { // SyntaxError: Invalid or unexpected token
    var e = r(80006), o = r(28327);
    t.exports = function(t) {
      ... // valid function content
    };
  }
  1. Case

Expected output in chunk:

  DE: [
    {
      start: 25398,
      end: 25398
    },
    ...
    {
      start: 26486,
      end: 26486
    },
    ...
  ]

Actual output:

  DE: [
    {
      start: 25398,
      end: 25398
    },
    ...
    {
      start: 436eb, // SyntaxError: Invalid or unexpected token
      end: 436eb // SyntaxError: Invalid or unexpected token
    },
    ...
  ]

Our webpack configuration about splitChunks is just

optimization: { splitChunks: { chunks: 'all' } } }

Does anyone know what could be causing this? What makes it extremely annoying is that this only happens randomly and only inside our CD pipeline. We haven't managed to reproduce the issue locally at all.

Thanks!

about 4 years ago · Santiago Trujillo
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda