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

useYoastHTML - some fields don't update when navigating between pages #699

Open
1 task done
johnwatkins0 opened this issue Feb 25, 2024 · 1 comment
Open
1 task done

Comments

@johnwatkins0
Copy link
Member

johnwatkins0 commented Feb 25, 2024

Describe the bug

While this is an issue on my project, I have also verified that it is occurring on another project using this framework.

When passing useYoastHtml into the Headless app component, the page metadata within the document head seems to be correct, but when navigating around the site via internal links, many of the fields don't update. The title component updates, but from what I can see, other fields don't.

Steps to Reproduce

  1. Navigate to a page on a site using the useYoastHTML option and open the document head in the Elements tab of your browser dev tools.
  2. Click an internal link on the page.
  3. Notice that the title updates but nothing else in the head.
  4. Completely refresh the page and see that the head does have the expected content.

Screenshots, screen recording, code snippet

No response

Environment information

No response

WordPress information

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@nicholasio
Copy link
Member

nicholasio commented Mar 2, 2024

I can replicate on your project but on the default project 🤔 .

This issue has been haunting us for a while.... In the past I was able to replicate this issue only when GTM was being added to the page but it doesn't seem to be the case now.

What I think it's happening though is that the page ends up with both the previous values and the new ones, so we need to find a way to clear up the old meta tags.

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

2 participants