Skip to content

[BUG] SSR not dynamic according to Nuxt routeRules #319

@adamskeeled

Description

@adamskeeled

My Nuxt3 app has the base SSR config enabled ssr: true, but then I have Nuxt routeRules to disable SSR in specific routes like the following:

routeRules: {
    '/test/**': {
        ssr: false,
    },
},

However, this module seems to only enable/disable SSR according to the base configuration, and is ignoring whether SSR is enabled for a specific route or not.
Meaning, if I access any page inside /test, and for example use useDisplay from Vuetify, it will show that SSR is enabled. If I disable SSR in the base nuxt config, then when using useDisplay it shows SSR as disabled.

Expected behaviour
The module should update the SSR configuration dynamically depending on whether that route that SSR enabled or not, just like Nuxt does.

Actual behaviour
Module is fetching the SSR configuration from the global base nuxt config and is ignoring whether SSR is enabled/disabled for a specific route.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions