Skip to content

SSR with Inertia, Vue, Vite, and vue-instantsearch #43417

Discussion options

You must be logged in to vote

Sorry I figured it out and forgot to come back here. I updated to Vite 3 and updated the laravel plugin to the latest. Finally I added several npm packages to ssr.noExternal in my vite config.
My vite.config.ts file now looks like this:

import {defineConfig} from 'vite';
import laravel from 'laravel-vite-plugin';
import vue from '@vitejs/plugin-vue';

export default defineConfig({
    plugins: [
        laravel({
            input: 'resources/js/app.js',
            ssr: 'resources/js/ssr.js'
        }),
        vue({
            template: {
                transformAssetUrls: {
                    base: null,
                    includeAbsolute: false,
                },
            },

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by ChristianPavilonis
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants