Example of Livewire/livewire in Hi-Folks/gh-actions-yaml-generator

File app/Http/Livewire/Dashboard/Daily.php (link to Github)
use App\Models\Configuration;
use App\Models\LogConfiguration;
use Illuminate\Support\Facades\DB;
use Livewire\Component;

class Daily extends Component
    public $daily;

    public function mount(): void
        $date = DB::raw('DATE(`created_at`) as `date`');
        if (config('database.default') === 'pgsql') {
            $date = DB::raw("date_trunc('day', created_at) as date");
        $this->daily = LogConfiguration::select(array(
            DB::raw('count(*) as count')
            ->orderBy('date', 'DESC') // or ASC
            ->pluck('count', 'date');
    public function render(): \Illuminate\View\View
        return view('livewire.dashboard.daily');
File resources/views/livewire/dashboard/daily.blade.php (link to Github)
<div class="flex flex-col">
  <div class="-my-2 overflow-x-auto sm:-mx-6 lg:-mx-8">
    <div class="py-2 align-middle inline-block min-w-full sm:px-6 lg:px-8">
      <div class="shadow overflow-hidden border-b border-gray-200 sm:rounded-lg">
          Daily configurations

        <table class="w-full divide-y divide-gray-200">
          <thead class="bg-gray-50">
            <x-table.th >Date</x-table.th>
            <x-table.th >Counts</x-table.th>

          <tbody class="bg-white divide-y divide-gray-200">

          @foreach($daily as $date => $count)
            <tr class="">
                {{ $date }}
              <x-table.td align="right">
                {{ $count }}

File resources/views/dashboard/index.blade.php (link to Github)
    <div class="max-w-7xl mx-auto py-1 sm:px-6 lg:px-8">

Additional resources on livewire/livewire: