-
-
Notifications
You must be signed in to change notification settings - Fork 12
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
No known conditions for "." specifier in "vite-aliases" package #54
Comments
"dependencies": { |
Failed to resolve entry for package "vite-aliases". The package may have incorrect main/module/exports specified in its package.json: No known conditions for "." specifier in "vite-aliases" package The only successful way is to import in this way import { ViteAliases } from "./node_modules/vite-aliases/dist/index" It seems that the path of "." of export in package.json has not been found, but I compared the package. json of vite and did not find any difference, and did not try to find a solution. I think the problem should not be in package.json |
Hey there! Sorry for the late response! So this issue has been posted multiple times already, but i cant seem to replicate it! I have asked the other issue creators before, if they could provide a test repo and check if the example of vite-aliases runs for them! - It works perfectly for me (using linux), but i unfortunately cannot test against windows anymore.. |
This solved it for me:
|
It happens on linux, too. One project I have works, the second doesnt. Havent figured out the difference yet. |
This issue seems to appear only if you dont have "type": "module" in your package.json. |
node_modules/.pnpm/[email protected]/node_modules/esbuild/lib/main.js:1365:27: ERROR: [plugin: externalize-deps] Failed to resolve entry for package "vite-aliases". The package may have incorrect main/module/exports specified in its package.json: No known conditions for "." specifier in "vite-aliases" package at failureErrorWithLog
The text was updated successfully, but these errors were encountered: