Setup for VILT stack (Can be used for TALL stack too)
All default SEO metatags are located inresources/views/seo/metatags.blade.php file.
In resources/views/app.blade.php file you can find @include('seo.metatags', ['seo' => $page['props']['seo'] ?? null]) which includes the metatags file into the layout file.
If you want to add SEO metatags to a specific page, you should add seo key to the page’s data array and pass the metatags array to it.
Example on BlogController.php:
BlogController.php
- Remove all meta tags from
resources/views/app.blade.phpfile. - Add the following code inside the
<head>component inresources/views/app.blade.phpfile:@include('seo.metatags', ['seo' => $page['props']['seo'] ?? null]) - Remove
<Head title="..."> ...fromresources/js/Layouts/HomeLayout.vuefile. - Remove
<Seo title="..." description="..."> ...fromresources/js/Pages/Article.vueandresources/js/Pages/Blog.vuefile and from everywhere you have added. - Follow the documentation above to add SEO metatags to your pages.
Setup for VILT stack [old, not recommended as the dynamic og images are not working properly]
Use `resources/js/Components/Seo.vue wrapper component to add SEO tags in your pages. Or, alternatively use Inertia’s<Head> component, which adds meta tags to the <head>.

