Skip to content

Commit e80661f

Browse files
committed
Add more export docs
1 parent 83f08d6 commit e80661f

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

exports-usage.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Export Usage
2+
3+
## Usage
4+
5+
1. Add the export-button livewire component on your view file that uses dataTable class.
6+
7+
```php
8+
<livewire:export-button :table-id="$dataTable->getTableId()" />
9+
```
10+
11+
2. On your `DataTable` class, use `WithExportQueue`
12+
13+
```php
14+
use Yajra\DataTables\WithExportQueue;
15+
16+
class PermissionsDataTable extends DataTable
17+
{
18+
use WithExportQueue;
19+
20+
...
21+
}
22+
```
23+
24+
3. Run your queue worker. Ex: `php artisan queue:work`

0 commit comments

Comments
 (0)