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

156
Visualizações
Get server response before axios response wrapper for functions

What I did

  • Set response wrapper for functions, services, and repositories class for Axios. This is called RepositoryResponse
  • Every request now will be in one structure {status,message,data, error, meta}

Now, from the backend, I am returning a downloadable Excel file as

 return Excel::download($report, 'coupons-report.xlsx');

What I see

The server response comes correctly and this is what I need to have. But when I log the response in the function, it comes empty.

Here is an image of what I mean The top response is the "raw" response (my target). However, the below one is the one I am getting when I return the response from this.$axios.get.

My question is how can I get the data on the top?

enter image description here

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