title: ERROR TypeError: this.data is not a function at
body: <p>i try to pass the variable of my alpha2code trough a another component so when i click on the row of my table it should show only the data according to the alpha2code.</p>
  
  <p>this is the function when i click on a specific row of the table</p>
  
  <pre><code>onRowClicked(row) {
  console.log('Row clicked: ', row);
  console.log(row.alpha2Code);
  this.data(row.alpha2Code);
   location.href="/country";
  }
  </code></pre>
  
  <p>this is setter to set the alpha2code from that row to the value in my service</p>
  
  <pre><code>set data(value: any) {
  this.getservice.alpha2Code = value;
  }
  </code></pre>
  
  <p>my service :</p>
  
  <pre><code>export class GetCountries {
  alpha2Code : any;
  constructor(private http: HttpClient) { }
  public GetAllStationCountries(){
  return this.http.get('https://restcountries.eu/rest/v2/all');
     }
  }
  </code></pre>
  
  <p>in my child component i try to bind that value from my parent to my child here,that has been set before :</p>
  
  <pre><code>public get data():any {
  return this.getservice.alpha2Code;  
  }
  </code></pre>
  
  <p>if i do something completely wrong , tell me. My first purpose was just to pass data from my parent component to my child so i can do i get from the country API with paramter the alpha2code so i make a dashboard with more detailed information about the country you just clicked on in the table</p>