Skip to content

extensions are wrongly added with addRelativeDeclarationExtensions and vue + setup #249

@pi0

Description

@pi0

(source: reported by @benjamincanac / reproduced on https://github.com/nuxt/ui/tree/847ee4591abee63cc503bf32d62341d16be6ebc5 dist/runtimes/types/index.ts after build)


#243 introduced a regression in 1.5.7+ with addRelativeDeclarationExtensions option since it assumes all source file will emit a .vue.d.ts companion while files with script setup are not transpiled (and therefore don't emit this file), they need type import with .vue

I have added snapshot tests to reproduce it:

export * as scriptSetupTS from "./script-setup-ts.vue.js";

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions