mirror of
https://github.com/archtechx/laravel-tips.git
synced 2025-12-12 05:14:04 +00:00
797 B
797 B
| title | tweet_id | thread_slug | author_username | images | created_at | slug | |
|---|---|---|---|---|---|---|---|
| Including a unique value, like now() or Str::random(), in the Blade template of a Livewire component is a great way to check if that part of the DOM is getting re-rendered | 1461703833617272840 | weekly-thread-2021-46 | alexjgarrett |
|
2021-11-19T14:32:05+00:00 | including-a-unique-value-like-now-or-strrandom-in-the-blade-template-of-a-livewire-component-is-a-great-way-to-check-if-that-part-of-the-dom-is-getting-re-rendered |
A quick and easy way to check if @LaravelLivewire components are re-rendering when you don't want/need them to.
Add now() or now()->timestamp to your component template. The time value will increment if there's a re-render side effect!