Skip to content

schema parsing of definiteRouteMeta does not take effect in vite mode #3786

Closed

Description

@halo951

Environment

Create a template project using 'create nitro app' and select 'vite', node version: 24.5.0

{
  "type": "module",
  "scripts": {
    "build": "vite build",
    "dev": "vite dev",
    "preview": "vite preview"
  },
  "devDependencies": {
    "nitro": "latest",
    "vite": "npm:rolldown-vite"
  }
}

Reproduction

  1. Add definiteRouteMeta to any interface
  2. Use Vite to start and access the _Swagger or doc API
  3. It can be seen that the routing properties defined by definiteRouteMeta have not been generated

Describe the bug

When running the Nitro app with Vite, the definiteRouteMeta definition does not take effect Normal startup performance when using Nitro.

Next week, I will try to read the source code and investigate the cause of the problem. If I find it, I will submit it to PR

Additional context

No response

Logs

Activity

  1. added
    pending triage
    on Nov 14, 2025
  2. added
    bug
    and removed
    pending triage
    on Sep 2, 2026
  3. pi0x commented on Sep 7, 2026

    @pi0x
    Contributor

    Fixed by 0256e17 (#4316): the route-meta plugin hooks now run with order: "pre", so defineRouteMeta is picked up under the Vite builder and shows up in the OpenAPI output — the PR adds a vite openapi fixture covering exactly that. Shipped in v3.0.260903-beta.

    Posted by an AI triage agent on behalf of a maintainer.

  4. added theissue type on Nov 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions