title: Unable to Filter Array from API on VueJS
body: <p>Im working on Nativescript-Vue app and im trying to solve this.</p>
  
  <p><strong>Situation</strong></p>
  
  <p>I receive data from API. Below is the structure of data that i receive from api</p>
  
  <pre><code>{
  "count": 9,
  "results": [
      {
          "id": 1,
          "createdOn": "2020-04-08T12:10:46.924551+05:45",
          "modifiedOn": "2020-04-08T12:10:47.236475+05:45",            
          "gender": "male",
          "age": 32,
          "status": "active",
  
      },
      {
          "id": 3,
          "createdOn": "2020-04-08T12:10:46.924551+05:45",
          "modifiedOn": "2020-04-08T12:10:47.236475+05:45",            
          "gender": "male",
          "age": 32,
          "status": "active",
  
      },
      {
          "id": 4,
          "createdOn": "2020-04-08T12:10:46.924551+05:45",
          "modifiedOn": "2020-04-08T12:10:47.236475+05:45",
          "age": 34,
          "status": "inactive",
  
      },
      {
          "id": 6,
          "createdOn": "2020-04-08T12:10:46.924551+05:45",
          "modifiedOn": "2020-04-08T12:10:47.236475+05:45",
          "age": 65,
         "status": "inactive",
      },
      {
          "id": 2,
          "createdOn": "2020-04-08T12:10:46.924551+05:45",
          "modifiedOn": "2020-04-08T12:10:47.236475+05:45",
          "age": 19,
          "status": "pending",
  
      },
  
  ]
  </code></pre>
  
  <p>Below is the vue code i have.</p>
  
  <pre><code> export default {
  data() {
  
      return{
          allData:[],
          total:[],
          active:[],
          inactive:[],
          pending:[]       
  
         }
  },
  mounted() {
     axios({ method: "GET", "url": "https://api.url" }).then(
         response =&gt;
         {            
  
               this.allData = response.data.results,
               this.total = response.data.count               
  
           }, error =&gt; {
              console.error(error);
          }
     )       
  },
  
  computed:{
          active(){
              return this.allData.filter((status)=&gt;{
                  return this.allData.status.match("active");
                   })
              }
  
          },
  
    }
  </code></pre>
  
  <p>My objective is to show the number of records with active, inactive and pending status in the app. Im using this snippet to do this for active.</p>
  
  <pre><code>&lt;Label class="numbers" :text="active.count" width="200" height="50" /&gt;
  </code></pre>
  
  <p>Can someone tell me where i am failing. </p>
  
  <p>Thanks in advance.
  Ashish A.</p>