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

alias normalization breaks config #130

Open
j4k0xb opened this issue Dec 22, 2023 · 0 comments
Open

alias normalization breaks config #130

j4k0xb opened this issue Dec 22, 2023 · 0 comments

Comments

@j4k0xb
Copy link

j4k0xb commented Dec 22, 2023

Repro: https://stackblitz.com/edit/vitejs-vite-z8v1wp?file=vite.config.js

It only errors when vite-plugin-solid is active:

Failed to load url /node_modules/path-browserify/posix (resolved id: /home/projects/vitejs-vite-z8v1wp/node_modules/path-browserify/posix) in /home/projects/vitejs-vite-z8v1wp/main.js. Does the file exist?

Specifically this line:

userConfig.resolve.alias = normalizeAliases(userConfig.resolve && userConfig.resolve.alias);

Seems like the normalization is not needed anymore since f3b10b5 and can be removed (works fine based on my tests).
I'll also try to find the root cause in vite or @rollup/plugin-alias.

Related: davidmyersdev/vite-plugin-node-polyfills#48 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant