Introducing Laravel Quizzes! Play now

Laravel Livewire Tables Documentation

This is the documentation for v2. You can switch versions in the menu at the top. Check your current version with the following command:

composer show rappasoft/laravel-livewire-tables

Creating Bulk Actions

There are 3 ways to define your bulk actions.

They all do the same thing except provide different levels of flexibility.

The key is the Livewire method to call, and the value is the name of the item in the bulk actions dropdown.

Property

The first way to define your bulk actions is with the bulkActions component property:

public array $bulkActions = [
    'exportSelected' => 'Export',
];

Method

You can also use the bulkActions method on the component:

public function bulkActions(): array
{
    return [
        'exportSelected' => 'Export',
    ];
}

Configuration

You can also set them via the component's configure method:

public function configure(): void
{
    $this->setBulkActions([
        'exportSelected' => 'Export',
    ]);
}