Skip to content

Outer folder type/interface import in SFC fails on Windows (path.posix.join issue) #9583

@b12k

Description

@b12k

Vue version

3.3.8

Link to minimal reproduction

https://github.com/b12k/vue-sfc-compiler-issue

Steps to reproduce

Easy way:

Can be reproduced by simply extending unit test with additional condition.
https://github.com/vuejs/core/pull/9478/files#diff-ba884e3c055eca4af5d6c4a16daa31397a191ceabac0a4018a2b612b781360b5R484-R489

See with own eyes way:

What is expected?

It should be possible to import type definitions from outer folders.

What is actually happening?

[@vue/compiler-sfc] Failed to resolve import source "../outer-folder"

Image

System Info

System:
  OS: Windows 11 Pro
Binaries:
  Node: 20.9.0 - ~\AppData\Local\fnm_multishells\70852_1699634305330\node.EXE
  Yarn: 1.22.19 - ~\AppData\Local\fnm_multishells\70852_1699634305330\yarn.CMD
npmPackages:
  vue: 3.3.8 => 3.3.8

Any additional comments?

This PR #9478 fixes this issue.

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