© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•3y ago•
5 replies
dasK_

3.2 Exporting CSV

Just upgraded to 3.2 so I can use the export action but hitting a wall when trying to add the ExportAction to getHeaderActions, it seems to work just fine in the table, but it just doesn't work in the header?


protected function getHeaderActions(): array
    {
        return [
            Actions\CreateAction::make(),
            ImportAction::make()
                ->importer(ProductImporter::class),
            ExportAction::make()
                ->exporter(ProductExporter::class)
        ];
    }

protected function getHeaderActions(): array
    {
        return [
            Actions\CreateAction::make(),
            ImportAction::make()
                ->importer(ProductImporter::class),
            ExportAction::make()
                ->exporter(ProductExporter::class)
        ];
    }


Removing ImportAction and leaving just Export still does the same thing.
Header actions must be an instance of Filament\Actions\Action, or Filament\Actions\ActionGroup.
Header actions must be an instance of Filament\Actions\Action, or Filament\Actions\ActionGroup.
Solution
You need to read docs clearly, everything is written here.. Outside table you use
use Filament\Actions\ExportAction;
use Filament\Actions\ExportAction;
and inside table you use
use Filament\Tables\Actions\ExportAction;
use Filament\Tables\Actions\ExportAction;
Notice the difference
Screenshot_from_2024-01-19_16-13-36.png
Jump to solution
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources
Was this page helpful?

Similar Threads

Recent Announcements

Similar Threads

[3.2.0] Export to CSV relationships
FilamentFFilament / ❓┊help
3y ago
Exporting Image's + CSV/Excel using Exporter
FilamentFFilament / ❓┊help
6mo ago
Bumped from 3 to 3.2 and getting Leage\Csv\Writer not found
FilamentFFilament / ❓┊help
2y ago
Login Route error while exporting csv files or viewing validation errors during csv import.
FilamentFFilament / ❓┊help
2y ago