Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

200
Views
Unable to catch Network Error when sending request using Inertia + Vue

While sending a this.$inertia.patch request I'm unable to catch a Network Error. I'm turning off the backend server to emulate a lost connection. The console shows: Uncaught (in promise) Error: Network Error.

I've tried Inertia's onError, tried adding a .catch after the request as well as a separate try...catch and used the Vue 2's

errorCaptured: function(err) {
   console.log('Caught error', err.message)
},

I can give more details if needed.

So basically trying to catch net::ERR_CONNECTION_REFUSED

Edit: I moved to using onFinish along with onSuccess and onStart, but finally used axios

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Use onStart along with onSuccess and onFinish:

  • In the case of a network error, onFinish will trigger without onSuccess.
  • In the case of a server error onError will trigger with onFinish
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!