Wireclick for column #743
-
Hi, Is there "wireclick" feature for column example to LinkColumn? |
Beta Was this translation helpful? Give feedback.
Answered by
rappasoft
Apr 27, 2022
Replies: 1 comment 1 reply
-
I would use: https://rappasoft.com/docs/laravel-livewire-tables/v2/datatable/available-methods#content-settrattributes public function configure(): void
{
// Takes a callback that gives you the current row and its index
$this->setTrAttributes(function($row, $index) {
return [
'wire:click' => 'myFunction('.$row->id.')',
];
});
} |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
jay2success
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I would use: https://rappasoft.com/docs/laravel-livewire-tables/v2/datatable/available-methods#content-settrattributes