Skip to content

fix(head): resolve reactive input before pushing to unhead - #1005

Open
Carpediem94 wants to merge 2 commits into
nuxt-modules:mainfrom
Carpediem94:fix/head-resolve-reactive-input
Open

fix(head): resolve reactive input before pushing to unhead#1005
Carpediem94 wants to merge 2 commits into
nuxt-modules:mainfrom
Carpediem94:fix/head-resolve-reactive-input

Conversation

@Carpediem94

@Carpediem94 Carpediem94 commented Aug 12, 2026

Copy link
Copy Markdown

Fixes #1004

🔗 Linked issue

Issue #1004

❓ 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

@unhead/vue's clientUseHead resolves reactive input with walkResolver(input, VueResolver) inside a watchEffect before pushing an entry. The composable this module registers in its place pushed the raw input, and the client head has no prop resolver of its own — @unhead/vue/server is the only one created with propResolvers: [VueResolver], which is why this never showed up during SSR.

I used Claude Opus 5 to analyze the problem and find a possible solution, before submit PR I review the code and make some changes on my own (I prefer to let "claude contribute" in the commit for transparency).
Currently I have already a workaround on my business projects to fix this error, so I decide to contribute to the repository.

@Carpediem94
Carpediem94 requested a review from danielroe as a code owner August 12, 2026 10:29
@netlify

netlify Bot commented Aug 12, 2026

Copy link
Copy Markdown

Deploy Preview for friendly-lamington-fb5690 ready!

Name Link
🔨 Latest commit 6355f95
🔍 Latest deploy log https://app.netlify.com/projects/friendly-lamington-fb5690/deploys/6a7c4b25c55d9700087903f4
😎 Deploy Preview https://deploy-preview-1005--friendly-lamington-fb5690.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@codecov

codecov Bot commented Aug 12, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 14 lines in your changes missing coverage. Please review.
✅ Project coverage is 28.10%. Comparing base (55664b7) to head (6355f95).

Files with missing lines Patch % Lines
src/runtime/composables/head.ts 0.00% 14 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1005      +/-   ##
==========================================
- Coverage   28.96%   28.10%   -0.86%     
==========================================
  Files          12       12              
  Lines         328      338      +10     
  Branches       98      100       +2     
==========================================
  Hits           95       95              
- Misses        233      243      +10     

☔ View full report in Codecov by Harness.
📢 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.

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

Successfully merging this pull request may close these issues.

useHead does not resolve reactive input on the client

1 participant