Skip to content

Issue with module augmentation seems to be happening again #807

@trc-mathieu

Description

@trc-mathieu

Environment


  • Operating System: Linux
  • Node Version: v20.13.1
  • Nuxt Version: 3.12.2
  • CLI Version: 3.12.0
  • Nitro Version: 2.9.6
  • Package Manager: [email protected]
  • Builder: -
  • User Config: -
  • Runtime Modules: -
  • Build Modules: -

Reproduction

You can simply clone this repository, open in VS code and navigate to playground-authjs/pages/index.vue and mouse over on auth key. The type is not correctly augmented.

Describe the bug

The MiddlewareMeta is not recognized by definePageMeta macro. This issue happened in the past and it is happening to me now.
The modification that was made here does fix the issue: #397 but it was rolled back by @danielroe here #582

I have this issue on other modules as well and augmenting from #app/../pages/runtime/composables does work.

@danielroe, do you mind trying again the latest version of this repo?

using #app
Screenshot 2024-07-16 at 9 58 55 AM
Screenshot 2024-07-16 at 9 59 05 AM

using #app/../pages/runtime/composables

Screenshot 2024-07-16 at 9 59 29 AM
Screenshot 2024-07-16 at 9 59 47 AM

Additional context

No response

Logs

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugA bug that needs to be resolvedp4Important Issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions