title: Dropdown search not worked when add new row
body: <p>I want to added dropdown search for quick search and select. Initially one row is define. Here dropdown search is work fine. But after completing this row want to add new row. it added but this time dropdown search is not working.</p>
  
  <p>Code is here</p>
  
  <p><a href="http://doctor.devmizanur.com/css/select2.min.css" rel="nofollow noreferrer">css</a>
  <a href="http://doctor.devmizanur.com/css/select2-bootstrap4.min.css" rel="nofollow noreferrer">css</a></p>
  
  <p>Initial Row</p>
  
  <pre><code>&lt;tr&gt;
                              &lt;td&gt;
                                  &lt;select id="category" class="form-control form-control-sm select2"&gt;
                                      &lt;option selected="false"  disabled&gt;Category&lt;/option&gt;
                                      @foreach($types as $type)
                                      &lt;option value="{{$type-&gt;id}}"&gt;{{$type-&gt;name}}&lt;/option&gt;
                                      @endforeach
                                  &lt;/select&gt;
                              &lt;/td&gt;
                              &lt;td&gt;
                                  &lt;!-- &lt;select id="generic" class="form-control form-control-sm selectpicker show-tick" data-live-search="true"&gt; --&gt;
                                  &lt;select id="generic" class="form-control form-control-sm select2" data-live-search="true"&gt;
                                      &lt;option selected="false"  disabled&gt;Generic&lt;/option&gt;
                                      @foreach($generics as $generic)
                                      &lt;option value="{{$generic-&gt;id}}"&gt;{{$generic-&gt;name}}&lt;/option&gt;
                                      @endforeach
                                  &lt;/select&gt;
                              &lt;/td&gt;
                              &lt;td&gt;
                                  &lt;select name="cmbMedicine[]" id="med" class="form-control form-control-sm duplicat select2"&gt;
                                      &lt;option selected="false"  disabled&gt;Medicine&lt;/option&gt;
                                  &lt;/select&gt;
                              &lt;/td&gt;
  &lt;/tr
  </code></pre>
  
  <p><a href="http://doctor.devmizanur.com/js/select2.full.min.js" rel="nofollow noreferrer">js</a></p>
  
  <p>Add New Row</p>
  
  <pre><code>$('.addRow').click(function() {
    addRow();
  });
  function addRow(){
    var addRow = '&lt;tr&gt;'+
                    '&lt;td&gt;'+
                        '&lt;select name="cmbProductCategory" id="category" class="form-control form-control-sm select2"&gt;'+
                              '&lt;option selected="false" disabled&gt;Category&lt;/option&gt;'+
                              '@foreach($types as $type)'+
                              '&lt;option value="{{$type-&gt;id}}"&gt;{{$type-&gt;name}}&lt;/option&gt;'+
                              '@endforeach'+
                        '&lt;/select&gt;'+
                    '&lt;/td&gt;'+
                    '&lt;td&gt;'+
                        '&lt;select name="cmbProductCategory" id="generic" class="form-control form-control-sm select3"&gt;'+
                              '&lt;option selected="false" disabled&gt;Generic&lt;/option&gt;'+
                              '@foreach($generics as $generic)'+
                              '&lt;option value="{{$generic-&gt;id}}"&gt;{{$generic-&gt;name}}&lt;/option&gt;'+
                              '@endforeach'+
                        '&lt;/select&gt;'+
                    '&lt;/td&gt;'+
                    '&lt;td&gt;'+
                        '&lt;select name="cmbProductInfo[]" id="medName" class="form-control duplicat select3"&gt;'+
                              '&lt;option selected="false" disabled&gt;Medicine&lt;/option&gt;'+
                        '&lt;/select&gt;'+
                    '&lt;/td&gt;';
    $('tbody').prepend(addRow);
  };
  </code></pre>
  
  <p>Initial Row</p>
  
  <p><a href="https://i.stack.imgur.com/knylb.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/knylb.jpg" alt="Initial row"></a></p>
  
  <p>When Add new row</p>
  
  <p><a href="https://i.stack.imgur.com/hURsQ.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/hURsQ.jpg" alt="When add new row"></a></p>