title: How to create filter by ng-model in ng-repeat
body: <p>I have this code </p>
  
  <p>
        </p>
  
  <pre><code>    &lt;div class="form-group"&gt;
        &lt;label for="inputFood" class="col-sm-2 col-form-label"&gt;Component&lt;/label&gt;
        &lt;br&gt;
        &lt;div class="col-sm-9 col-xs-9"&gt;
          &lt;input type="text" class="form-control" name="inputFood{{ $index + 1}}" id="inputFood{{$index+1}}" required ng-model="foodForm.inputFood[$index+1]" placeholder="Type a component" autocomplete="off" ng-keyup="doCheck($index+1)"&gt;
        &lt;/div&gt;
  
      &lt;/div&gt;
      &lt;br&gt;
      &lt;div class="form-group col-xs-12"&gt;
        &lt;ul ng-show="showListFood" class="foodList{{$index+1}}"&gt;
          &lt;li ng-click="showFood(foodN.food_name, foodN.food_id)" ng-repeat="foodN in foodName| filter : foodForm.inputFood.$index+1"&gt;
            &lt;span&gt;{{ foodN.food_name}}&lt;/span&gt;
          &lt;/li&gt;
        &lt;/ul&gt;
      &lt;/div&gt;
    &lt;/fieldset&gt;
  </code></pre>
  
  <p>And i'm trying to filter list by ng-model in ng-repeat, but sadly i don't succeed. I would be very thankful for some help. </p>
  
  <p>This is the example <a href="https://jsfiddle.net/odedtaizi/g88quyk1/10/" rel="nofollow noreferrer">jsFiddle</a> </p>