tiagospem / simple-tables
Fund package maintenance!
Tiagospem
www.paypal.com/donate/?hosted_button_id=E3HXK2FPPAL86
Requires
- php: ^8.3.0
- livewire/livewire: ^3.6.0
Requires (Dev)
- laravel/framework: ^11.0|^12.0
- laravel/pint: ^1.21.0
- orchestra/testbench: ^9.11|^10.0
- pestphp/pest: ^3.7.4
- pestphp/pest-plugin-livewire: ^3.0
- pestphp/pest-plugin-type-coverage: ^3.3.0
- phpstan/phpstan: ^1.12.19
- rector/rector: ^1.2.10
- symfony/var-dumper: ^7.2.3
This package is auto-updated.
Last update: 2025-08-26 17:24:24 UTC
README
A powerful Laravel Livewire package that simplifies the creation of interactive, feature-rich data tables with minimal effort.
Overview
Livewire Simple Tables is designed to help Laravel developers quickly build beautiful, interactive data tables without the complexity often associated with table implementations. This package leverages Laravel Livewire to provide a reactive, real-time user experience.
Features
- Easy to Set Up: Get started with just a few lines of code
- Powerful Data Management: Built-in pagination, sorting, and searching
- Customizable Filters: Create dependent, reactive filters to narrow down data
- Interactive Actions: Add row-level actions and bulk operations
- Row Detail Views: Expand rows to show additional information
- Beautifully Styled: Built with Tailwind CSS for a clean, modern look
- Highly Extensible: Create custom themes, filters, and components
Installation
composer require tiagospem/simple-tables
For detailed installation instructions, see the Installation Guide.
Quick Start
Create a Table Component
php artisan st:create table UsersTable
Implement the Table Component
<?php namespace App\Livewire; use App\Models\User; use Illuminate\Database\Eloquent\Builder; use TiagoSpem\SimpleTables\Column; use TiagoSpem\SimpleTables\SimpleTableComponent; class UsersTable extends SimpleTableComponent { public function columns(): array { return [ Column::text('ID', 'id')->sortable(), Column::text('Name', 'name')->sortable()->searchable(), Column::text('Email', 'email')->searchable(), Column::text('Created At', 'created_at')->sortable(), ]; } public function datasource(): Builder { return User::query(); } }
Add to Your Blade View
<div> <h1>Users</h1> <div class="mt-4"> <livewire:users-table /> </div> </div>
Documentation
For comprehensive documentation, visit https://tiagospem.github.io/livewire-simple-tables/
Requirements
- PHP 8.3+
- Laravel 10+
- Livewire 3.5.4+
- Tailwind CSS v3
License
This package is open-sourced software licensed under the MIT license.