Skip to content

feat(vue-router): add styles to Vue RouteMatchExtensions augmentation #7319

@coderabbitai

Description

@coderabbitai

Summary

The RouteMatchExtensions interface in packages/vue-router/src/Matches.tsx is missing a styles field, unlike the React and Solid counterparts which include it.

This gap pre-dates PR #7311 (feat: add support for deferred head loading), which added key?: string support to the existing fields but did not introduce the missing styles entry for Vue.

Required Change

Add the following field to the RouteMatchExtensions module augmentation in packages/vue-router/src/Matches.tsx:

styles?: Array<
  (Vue.ComponentOptions['style'] & { key?: string }) | undefined
>

This should be placed alongside meta, links, scripts, and headScripts to match the React/Solid augmentations and provide full type coverage for keyed/deferred head().styles in Vue.

References

/cc @romulovalez

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