Laravel 8 - Jetstream + inertia.js - Vue dev tools not working

Stefan Bogdanescu

Founder & Senior Architect · 2026-06-29

Laravel Company

Laravel 8 - Jetstream + Inertia.js - Vue Dev Tools Not Working: A Deep Dive into Debugging Bundles

As a senior developer working with modern stacks like Laravel, Inertia.js, and Vue.js, debugging build and tooling issues can often feel like chasing ghosts. You have the application running fine in the browser, but the developer tools refuse to recognize your Vue component structure. This usually signals an issue not with the runtime code itself, but with how the assets are being bundled, compiled, or served.

This post dives into a common, frustrating scenario: why Vue DevTools might fail to detect your application when using Laravel Mix and Inertia.js. We will analyze the provided configuration and explore the likely culprits and definitive solutions.

The Symptom: Invisible Applications in DevTools

When you see "Vue not detected" across both development and production environments, it strongly suggests that the browser is loading the HTML and CSS correctly, but the JavaScript bundle either fails to load properly, or the module resolution required by the Vue DevTools extension cannot trace back to the original source files.

The core of this problem often lies in the interaction between your asset pipeline (Webpack/Mix) and how Inertia injects data into the page structure.

Analyzing the Setup: Code Context

Let's examine the provided configuration to pinpoint where the breakdown might occur:

1. The Vue Entry Point (app.js)

require("./bootstrap");

// Import modules...
import { createApp, h } from "vue";
import {
    App as InertiaApp,
    plugin as InertiaPlugin,
} from "@inertiajs/inertia-vue3";

const el = document.getElementById("app");

createApp({
    render: () =>
        h(InertiaApp, {
            initialPage: JSON.parse(el.dataset.page),
            resolveComponent: (name) => require(`./Pages/${name}`).default,
        }),
})
    .mixin({ methods: { route } })
    .use(InertiaPlugin)
    .mount(el);

This code correctly sets up the Inertia integration within a Vue 3 application. The use of require() suggests a CommonJS module system, which is standard when using older setups like Laravel Mix. The key here is ensuring that all dependencies are resolved correctly during the bundling phase.

2. The Asset Compilation (wepack.mix.js)

const mix = require("laravel-mix");

mix.js("resources/js/app.js", "public/js")
    .vue() // Crucial for Vue support
    .postCss("resources/css/app.css", "public/css", [
        require("postcss-import"),
        require("tailwindcss"),
        require("autoprefixer"),
    ])
    .webpackConfig(require("./webpack.config"));

// ... rest of the mix configuration

This file dictates how Laravel Mix compiles your assets. The .vue() method tells Mix to handle Vue Single File Components (SFCs). If the underlying webpack.config is not correctly configured to handle ES Modules and source maps for Vue, this process can fail silently regarding debugging information.

Diagnosing and Fixing the Issue

When DevTools fails to detect the application, follow these steps systematically:

Step 1: Verify Source Maps (The Most Likely Culprit)

Source maps are essential; they map the bundled, minified code back to your original source files (app.js, .vue files). Without them, the browser cannot effectively inspect the execution flow for debugging tools.

Action: Ensure your webpack.config is correctly generating source maps. For Vue projects compiled via Mix, this often involves ensuring the configuration passed into Webpack properly handles the transpilation steps. Check if your custom webpack.config includes appropriate settings for outputting .map files alongside the JS bundles.

Step 2: Inspect the Build Output

Check the console output during the npm run dev or npm run watch process. Look for any warnings or errors related to Webpack, Babel, or PostCSS. A failed compilation step here is often the root cause of missing debugging hooks.

Step 3: Check Module Loading in Blade

Ensure that your main blade file correctly loads the compiled script. Your setup using mix('js/app.js') is correct for this purpose. If the script fails to load entirely (e.g., a 404 error on the JS file), no DevTools can attach.

Conclusion: Embracing Laravel's Ecosystem

Debugging frontend tooling in a full-stack framework like Laravel requires understanding the entire pipeline—from PHP routing to asset compilation and browser interpretation. The issue you are facing is rarely an error in Vue code itself; it’s almost always a configuration mismatch between your build tool (Webpack/Mix) and the environment expectations of the developer tools.

By meticulously checking your source maps and ensuring that the Webpack configuration correctly processes Vue modules, you can resolve these frustrating detection issues. Remember, leveraging the robust ecosystem provided by Laravel makes this process smoother; keep exploring the resources available at https://laravelcompany.com for staying updated on best practices in the PHP world. Happy coding!