title: Laravel Livewire javascript code after model is load
body: <p>I have one Laravel Livewire model open as bellow code</p>
  <pre class="lang-php prettyprint-override"><code>public function confirmItemAdd() 
  {
      $this-&gt;resetValidation();
      $this-&gt;confirmingItemAdd = true;
  }
  </code></pre>
  <p>and my model window code in blade is</p>
  <pre><code>&lt;x-jet-dialog-modal wire:model=&quot;confirmingItemAdd&quot;&gt;
  </code></pre>
  <p>I have one select2 in model and want to set value of <code>select2</code> on variable name <code>$s2v</code>
  After search I findout that</p>
  <pre><code>$('.select2').val(s2v).trigger('change');
  </code></pre>
  <p>how can I set value of select2 on load on model?</p>
  <p>Thanks</p>