title: Callback in interface with parameters
body: <p>I'm currently implementing a generic dropdown menu element using Angular (v8.0.1). Therefore, I planned on creating the dropdown with an array of elements of a specific interface such as can be seen below:</p>
  
  <pre><code>export interface DropdownSettings {
      title: string;
      callback: (...params: any) =&gt; any;
  }
  </code></pre>
  
  <p>For each possible dropdown option, an object of the interface is created an passed to the component;</p>
  
  <pre><code>public filter_options: DropdownSettings[] = [
      {
          title: 'Date ascending',
          callback: ??
      },
      ...
  }
  </code></pre>
  
  <p>Where the options are then passed to the component using a standard input:</p>
  
  <pre><code>&lt;dropdown title="Filter"
            [options]="filter_options"&gt;
  &lt;/dropdown&gt;
  </code></pre>
  
  <p>If a user selects an element in the dropdown, the set callback should be called performing some actions on a dataset that is passed. The callback itself is called in the following manner within the dropdown-menu components implementation:</p>
  
  <pre><code>elementSelected(callback: (??) =&gt; void) {
      callback(??);
      this.toggleVisible();
  }
  </code></pre>
  
  <p>The problem that arises is the following and also marked with the questionmarks. Within the callback function I don't have direct access on private member variables, which makes sense since the scope changes. However, I'd also preferably avoid passing, say a huge dataset to the component. This is simply because the dropdown menu itself does not have to have access to this data. Therefore I'd like to specify a function that is marked private or static within the component the dropdown menu is created, meaning, that all operations will be performed within the parent-component itself.</p>
  
  <pre><code>private static filterByDate(dataset: Redeem[]): void {
      dataset.sort((a: Redeem, b: Redeem) =&gt; {
          a = new Date(a.created_at);
          b = new Date(b.created_at);
          return a &gt; b ? -1 : a &lt; b ? 1 : 0;
      });
  }
  </code></pre>
  
  <p>So the main question that arises is: 
  How can I specify a callback function in an interface with additional parameters?</p>