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

145
Visualizações
Vue.js builder produces incorrect paths in index.html

The problem is that after building vue app in destination folder there is index.html with incorrect paths to static assets. Links look like

<link href="/static/js/chunk-29e00bf1.49e28fbb.js" rel="prefetch">

which is incorrect, but should be

<link href="static/js/chunk-29e00bf1.49e28fbb.js" rel="prefetch">

And browser look into ///D:/static/js/ instead of D://.../build/dist/static/js .

There is my vue.config.js

module.exports = {
  outputDir: './build/dist/',
  assetsDir: './static', //...
about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

Use publicPath property, and set the path to ./ to use relative paths on build.

module.exports = {
    ...
    publicPath: "./"
    ...
}

Read more in the official documentation: publicPath

about 4 years ago · Juan Pablo Isaza Relatório
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