Skip to content

fix(init): skip modules that are dependencies of other modules - #879

Merged
danielroe merged 8 commits into
nuxt:mainfrom
HugoRCD:fix/875
Jun 10, 2025
Merged

fix(init): skip modules that are dependencies of other modules#879
danielroe merged 8 commits into
nuxt:mainfrom
HugoRCD:fix/875

Conversation

@HugoRCD

@HugoRCDHugoRCD commented May 13, 2025

Copy link
Copy Markdown
Member

🔗 Linked issue

Resolves#875

❓ Type of change

  • 📖 Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • 👌 Enhancement (improving an existing functionality)
  • ✨ New feature (a non-breaking change that adds functionality)
  • 🧹 Chore (updates to the build process or auxiliary tools and libraries)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

📚 Description

@HugoRCD
HugoRCD requested a review from danielroe as a code ownerMay 13, 2025 12:10
@codecov-commenter

codecov-commenter commented May 13, 2025

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 43 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (main@fe091bf). Learn more about missing BASE report.

Files with missing linesPatch %Lines
packages/nuxi/src/commands/init.ts0.00%43 Missing ⚠️
Additional details and impacted files
@@ Coverage Diff @@## main #879 +/- ##
=======================================
Coverage ? 12.51% =======================================
Files ? 71 Lines ? 3723 Branches ? 101 =======================================
Hits ? 466 Misses ? 3225 Partials ? 32 

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@pkg-pr-new

pkg-pr-newBot commented May 13, 2025

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/create-nuxt@879
npm i https://pkg.pr.new/nuxi@879
npm i https://pkg.pr.new/@nuxt/cli@879

commit: 739ac3a

@codspeed-hq

codspeed-hqBot commented Jun 10, 2025

Copy link
Copy Markdown

CodSpeed Performance Report

Merging #879 will not alter performance

Comparing HugoRCD:fix/875 (10fa58e) with main (fe091bf)

Summary

✅ 2 untouched benchmarks

Comment threadpackages/nuxi/src/commands/init.ts Outdated

const allDependencies: Record<string, string[]> = {}
for (const module of modules) {
allDependencies[module] = await getModuleDependencies(module)

@danielroedanielroeJun 10, 2025

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we probably also want to get the dependencies of the template that's been installed (and not prompt to install any modules it contains), but that can be for another pr

for example, if you run pnpm create nuxt -t ui, it probably should not prompt to install @nuxt/fonts (or allow you to do so).

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll try to make a PR for that too!

@danielroedanielroe changed the title feat: skip already handled modules by @nuxt/uifix(init): skip modules that are dependencies of other modulesJun 10, 2025
@danielroe
danielroe merged commit 5fb3707 into nuxt:mainJun 10, 2025
@github-actionsgithub-actionsBot mentioned this pull request Jun 10, 2025
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Never install @nuxt/fonts or @nuxt/icon if @nuxt/ui is selected

3 participants

@HugoRCD@codecov-commenter@danielroe