kirby-seo
kirby-seo copied to clipboard
Split the title element from the seo/head snippet
trafficstars
First of all, thank you for this wonderful plugin!
Would it be useful to add a way to split the title element from the seo/head snippet?
For performance reasons, it makes sense to structure the elements in the head so that the SEO and meta tags are at the end. However, the title element should be integrated as early as possible.
<head>
<meta charset |http-equiv| viewport />
<title></title>
<!-- preconnect -->
<script src="" async></script>
<!-- CSS that includes @import -->
<!-- Synchronous JS -->
<!-- Synchronous CSS -->
<!-- preloads -->
<script src="" defer></script>
<!-- prefetch / prerender -->
<!-- Everything else ('SEO' meta tags, icons, Open Graph, etc.) -->
</head>
if anyone wants to implement this, I would make it a solution based on slots. if slots: true is passed to the snippet, it should output "priority" values, the slot, all other values. Priority could be specified here: https://github.com/tobimori/kirby-seo/blob/main/classes/Meta.php#L128 maybe?