Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Undeclaring paths alias causes a incorrect match result #65

Open
2 tasks
emosheeep opened this issue Jan 12, 2024 · 2 comments
Open
2 tasks

Undeclaring paths alias causes a incorrect match result #65

emosheeep opened this issue Jan 12, 2024 · 2 comments
Labels
bug Something isn't working pr welcome

Comments

@emosheeep
Copy link

emosheeep commented Jan 12, 2024

Problem

I don't declare a path alias link '@libs/*', and when I use a matcher created by createPathsMatcher, it results

@libs/constants → /cwd/@libs/constants

It doesn't make sense and should return undefined.

image

Expected behavior

It should return null if it matches nothing.

Minimal reproduction URL

https://stackblitz.com/edit/vitejs-vite-2pqdvg?file=index.mjs,tsconfig.json,package.json&terminal=dev

Version

4.7.2

Node.js version

18

Package manager

npm

Operating system

macOS

Contributions

  • I plan to open a pull request for this issue
  • I plan to make a financial contribution to this project
@emosheeep emosheeep added the bug Something isn't working label Jan 12, 2024
@privatenumber
Copy link
Owner

Thanks for the bug report! Happy to accept a PR

@emosheeep
Copy link
Author

I made some changes, please check it out 🫶

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working pr welcome
Projects
None yet
Development

No branches or pull requests

2 participants