@extends('layouts.app') @section('title', 'Blog') @section('content') @php $read = fn ($b) => max(1, (int) ceil(str_word_count(strip_tags((string) $b->content)) / 200)); $first = $blogs->first(); $rest = $blogs->slice(1)->values(); @endphp

Our blog

@if ($first) @if ($first->image_url){{ $first->title }}@endif Latest {{ \Illuminate\Support\Carbon::parse($first->created_at)->format('d M Y') }} {{ $read($first) }} min read

{{ $first->title }}

{{ $first->excerpt }}

Read the story
@if ($rest->count())
@foreach ($rest as $b) @if ($b->image_url){{ $b->title }}@endif {{ \Illuminate\Support\Carbon::parse($b->created_at)->format('d M Y') }} {{ $read($b) }} min read

{{ $b->title }}

{{ \Illuminate\Support\Str::limit($b->excerpt, 120) }}

Read more
@endforeach
@endif @else

No posts yet. Please check back soon.

@endif
@endsection