F
Filamentβ€’5mo ago
kennyhorna

Repeater item id

Hello, Is there a way to access the item id (or uuid) within the element? For example, to have it available in the >formatStateUsing(callback) Thanks in advance.
Solution:
inject $component and use str($component->getId())->beforeLast('.')->afterLast('.')
Jump to solution
2 Replies
Solution
LeandroFerreira
LeandroFerreiraβ€’5mo ago
inject $component and use str($component->getId())->beforeLast('.')->afterLast('.')
kennyhorna
kennyhornaOPβ€’5mo ago
@Leandro Ferreira That worked. Thank you πŸ™‚
Want results from more Discord servers?
Add your server