Skip to content

improve the warning in inject #13287

@gurgeous

Description

@gurgeous

I believe it's coming from this line:

warn(`inject() can only be used inside setup() or functional components.`)

I started seeing a lot of this warning after a recent upgrade. I thought it was my code but turned out to be Nuxt UI. Including the key in the warning would be helpful.

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