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

engrkashi's avatar

Laravel 10 vite build issue

I have used Vite with Laravel 10, I have also added vue3 to my laravel app. Its working on the localhost, when run with npm run dev, but once created a build, I am getting this issue: Uncaught SyntaxError: 60 at Ie (app-0c92f64c.js:4:72612)

My vite.config.js is: // vite.config.js import { defineConfig } from 'vite'; import laravel from 'laravel-vite-plugin';

import vue from '@vitejs/plugin-vue'

export default defineConfig({ plugins: [

    vue({
        template: {
            transformAssetUrls: {
                base: null,
                includeAbsolute: false,
            },
        },
    }),

    laravel({
        input: ['resources/css/app.css', 'resources/js/app.js', 'resources/js/admin-order-detail.js'],
        refresh: true,
    }),
],

});

0 likes
2 replies
Braunson's avatar

Have you tried to narrow down the issue? Try removing the resource/js/admin-order-detail.js from the input and rebuild, if it passes, there's something wrong in that file. Check your app.js, comment out some code, rebuild, any issues?

engrkashi's avatar

@Braunson The problem was with the vue-loader package, I have updated that and it worked for me. Thanks!

Please or to participate in this conversation.