mirror of
https://github.com/HolgerHatGarKeineNode/einundzwanzig-app.git
synced 2025-12-20 01:30:15 +00:00
🛠️ Enhance SEO: Add meta tags for services and meetups landing pages, including dynamic title, description, and image handling
This commit is contained in:
@@ -4,8 +4,8 @@ use App\Attributes\SeoDataAttribute;
|
||||
use App\Models\Meetup;
|
||||
use App\Models\MeetupEvent;
|
||||
use App\Traits\SeoTrait;
|
||||
use Livewire\Volt\Component;
|
||||
use Flux\Flux;
|
||||
use Livewire\Volt\Component;
|
||||
|
||||
new
|
||||
#[SeoDataAttribute(key: 'meetups_landingpage')]
|
||||
@@ -44,6 +44,16 @@ class extends Component {
|
||||
}
|
||||
}; ?>
|
||||
|
||||
@section('meta')
|
||||
@php
|
||||
$SEOData = SeoDataAttribute::getData('meetups_landingpage');
|
||||
$SEOData->title = $this->meetup->name;
|
||||
$SEOData->description = $this->meetup->intro ? str($this->meetup->intro)->limit(50) : $SEOData->description;
|
||||
$SEOData->image = $this->meetup->getFirstMediaUrl('logo');
|
||||
@endphp
|
||||
{!! seo($SEOData)->render() !!}
|
||||
@endsection
|
||||
|
||||
<div class="container mx-auto px-4 py-8">
|
||||
<div class="grid grid-cols-1 lg:grid-cols-2 gap-8">
|
||||
<!-- Left Column: Meetup Details -->
|
||||
|
||||
Reference in New Issue
Block a user