- What Laravel and Livewire versions does mrcatz/datatable support?
- The package officially supports Laravel 11, 12, and 13 with Livewire 3.x or 4.x. It will not work with Livewire 2.x or older Laravel versions. Always check the [GitHub releases](https://github.com/mrc4tz/mrcatz-datatables/releases) for version-specific notes before upgrading.
- How do I scaffold a CRUD admin page with MrCatz?
- Run `php artisan mrcatz:make Product --path=Admin` to generate a full CRUD page for a `Product` model. This creates a Livewire component, routes, and Blade templates in the `Admin/Product` directory. Customize the generated class by extending `MrCatzDataTables` for additional logic.
- Can I use MrCatz DataTable without DaisyUI?
- Yes, but with limitations. The package relies on DaisyUI for UI components like checkboxes and popovers. If you’re using a custom UI framework (e.g., Bootstrap, Bulma), you’ll need to override the Blade templates in `resources/views/vendor/mrcatz/` or manually style the components with Tailwind.
- How do I add advanced filters like dependent dropdowns?
- Use the `addFilter()` method in your Livewire component. For dependent filters, chain callbacks like `addFilter('category')->select()->dependentOn('brand')`. The package supports select filters, date ranges, and custom callbacks for complex logic. Refer to the [documentation](https://datatable.catzoid.tech) for syntax examples.
- Does MrCatz support inline editing for all column types?
- Yes, inline editing works out of the box for text, numbers, and boolean fields. For complex data (e.g., relationships, JSON), you’ll need to override the `editCell()` method in your component. The package provides hooks to customize the edit behavior for any column type.
- How do I enable exports (PDF/CSV/Excel) for my datatable?
- Install the required packages: `composer require maatwebsite/excel barryvdh/laravel-dompdf`. Then enable exports in your component by calling `enableExport()` and configuring the export buttons. Note that large datasets may impact performance; test with your expected data volume.
- What’s the best way to customize the UI beyond DaisyUI?
- Override the Blade templates in `resources/views/vendor/mrcatz/`. For Tailwind-specific tweaks, extend the base styles in your `app.css` or use `@layer` directives. The package uses Tailwind’s utility classes, so you can override styles by targeting the relevant classes (e.g., `.mr-catz-table`).
- Are there performance concerns with Meilisearch integration?
- Meilisearch is a beta feature and adds network latency for search queries. For production, ensure your Meilisearch instance is properly indexed and scaled. Fallback to Scout or simple Laravel search if Meilisearch isn’t critical. Test with your expected dataset size to validate response times.
- How do I handle complex query filters that don’t fit the standard API?
- Use the `addCustomFilter()` method to inject raw query logic. For example, `addCustomFilter(fn($query) => $query->whereHas('relation', fn($q) => $q->where('active', true)))` adds custom Eloquent constraints. Test thoroughly, as callback filters can behave differently in exports or bulk actions.
- What alternatives exist if MrCatz doesn’t fit my stack?
- For Laravel Livewire, consider **Filament** (batteries-included admin panels) or **Laravel Nova** (official admin tool). For lightweight tables, **Yajra/Box** or **Tabulator** (JavaScript-based) are alternatives. If you need a non-Livewire solution, **Inertia.js with React/Vue** paired with a custom table library may work better.