Skip to content

svelte:head to allow ordering because meta tags are underneath script tagsΒ #12055

@gregg-cbs

Description

@gregg-cbs

Describe the problem

When setting metadata through the svelte:head tag there is no way to specify that you want the meta tags to be at the top of the documents head tag. It seems svelte is mounting script tags above the meta tags.

image

In production on my website W3 Validator is complaining that the meta tags are last in the head tag and that they are changing on mount:
image

Whether or not this is affects metadata or seo im not sure but it is still something worth noting. We all know for the test of time meta tags come at the top of the head tag and scripts follow suit in the head or body.

Describe the proposed solution

It would be great if we could specify the order of the svelte:head so we can set our metadata svelte:head to be above the script tags or if svelte offered a way to set metadata similar to how nextjs does it or automagically sorted the head tags so meta tags are first.

Importance

nice to have

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions