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

"Issues with peer dependencies found" when installing @astrojs/preact #12805

Open
1 task
lilnasy opened this issue Dec 21, 2024 · 2 comments
Open
1 task

"Issues with peer dependencies found" when installing @astrojs/preact #12805

lilnasy opened this issue Dec 21, 2024 · 2 comments
Labels
- P2: nice to have Not breaking anything but nice to have (priority) good first issue Good for newcomers. If you need additional guidance, feel free to post in #dev on Discord pkg: preact Related to Preact (scope)

Comments

@lilnasy
Copy link
Contributor

lilnasy commented Dec 21, 2024

Astro Info

Astro                    v5.1.0
Node                     v18.20.3
System                   Linux (x64)
Package Manager          pnpm
Output                   static
Adapter                  none
Integrations             @astrojs/preact

If this issue only occurs in one browser, which browser is a problem?

No response

Describe the Bug

The preact template logs warnings when installing.

 WARN  Issues with peer dependencies found
.
└─┬ @astrojs/preact 4.0.1
  └─┬ @preact/preset-vite 2.8.2
    └── ✕ unmet peer vite@"2.x || 3.x || 4.x || 5.x": found 6.0.5 in @astrojs/preact

@preact/preset-vite has been pinned since this PR:

What's the expected result?

The template can be installed without any warnings.

Link to Minimal Reproducible Example

astro.new/framework-preact

Participation

  • I am willing to submit a pull request for this issue.
@github-actions github-actions bot added the needs triage Issue needs to be triaged label Dec 21, 2024
@ascorbic ascorbic added pkg: preact Related to Preact (scope) - P2: nice to have Not breaking anything but nice to have (priority) good first issue Good for newcomers. If you need additional guidance, feel free to post in #dev on Discord and removed needs triage Issue needs to be triaged labels Jan 3, 2025
@ascorbic
Copy link
Contributor

ascorbic commented Jan 3, 2025

If somebody would like to check if it's ok to unpin and upgrade @preact/preset-vite that would be great.

@Mitsunee
Copy link

Mitsunee commented Jan 6, 2025

fwiw downgrading Astro (in order to downgrade vite) does not fix this issue and produces the following setup (pnpm why vite):

dependencies:
@astrojs/preact 4.0.1
├─┬ @preact/preset-vite 2.8.2
│ ├─┬ @prefresh/vite 2.4.6
│ │ └── vite 6.0.7 peer
│ └── vite 6.0.7 peer
└── vite 6.0.7
astro 4.16.18
├── vite 5.4.11
└─┬ vitefu 1.0.5
  └── vite 5.4.11 peer

Note that vite 6.0.7 is listed as a direct dependency of @astrojs/preact here, while Astro itself uses a different version. It seems that there is a version conflict within the @astrojs/preact package.

Edit: the latest known good setup is [email protected] @astrojs/[email protected]. I have not tested whether it's safe to ignore the warning as I am currently resolving other unrelated conflicts that may or may not impact testing. Having @preact/preset-vite upgraded would be the optimal solution if possible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
- P2: nice to have Not breaking anything but nice to have (priority) good first issue Good for newcomers. If you need additional guidance, feel free to post in #dev on Discord pkg: preact Related to Preact (scope)
Projects
None yet
Development

No branches or pull requests

3 participants