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

Prepend title instead of appending to meta items #1913

Open
wants to merge 1 commit into
base: v1
Choose a base branch
from

Conversation

RobertBoes
Copy link
Contributor

@RobertBoes RobertBoes commented Jul 5, 2024

Currently when using SSR and the Inertia head component, the title is appended to the meta items.

Taking an example from the docs:

<Head>
  <title>Your page title</title>
  <meta name="description" content="Your page description">
</Head>

This would render in the HTML as;

<meta name="description" content="Your page description">
<title inertia>Your page title</title>

Since the title is somewhat of a special element the user doesn't have any control over where it's placed in the HTML. Rendering it as the first element would make more sense to me.
(edit: removed the part about SEO, as that's not of a concern)

@derrickreimer
Copy link
Contributor

Interesting, I've never heard of this as an SEO factor before. Is there a source on that intel?

@RobertBoes
Copy link
Contributor Author

@derrickreimer Interesting, I've never heard of this as an SEO factor before. Is there a source on that intel?

Ah my bad, you're right, think I confused it with the charset and viewport meta tags. Then there's not really a need to prepend it, apart from it looking nicer

@reinink reinink changed the base branch from master to v1 October 9, 2024 15:24
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.

2 participants