Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

ahinkle's avatar

Inertia: Gracefully handling "AxiosError: Network Error"

I'm encountering an intermittent "AxiosError: Network Error" in Sentry, predominantly with users likely having poor internet connections. The error surfaces when using the router function in Inertia to manage routing. Some example code:

Note: using Ziggy.js

router.visit(
    route('manual.show', {
        manual: manualData.slug,
        topic: selectedTopic.id,
        section: nestedSection.id
    }),
    {
        only: ['topic', 'section'],
    }
)

Given the symptoms and the very low rate it happens, I suspect the issue might be related to network timeouts. Is there a recommended approach in Inertia to handle or gracefully recover from such timeouts? I'm using Inertia version 1.0.15

0 likes
0 replies

Please or to participate in this conversation.