title: Sorting typescript array of accanted strings?
body: <p>I'm trying to sort my array by group and then identifier fields, which works fine, until one of the strings contains a special character, for example <code>Á</code> or <code>Ű</code>.</p>
  
  <p>Is there any kind of typescript or ng-2 specific method or sth to solve my problem?</p>
  
  <p>Example sorting method:</p>
  
  <pre><code>private someSortingMethod(): void {
          this.sortable= this.sortable.sort((t1: SomeThing, t2: SomeThing): number =&gt; {
              if (t1.group &lt; t2.group) return -1;
              if (t1.group &gt; t2.group) return 1;
              if (t1.identifier &lt; t2.identifier) return -1;
              if (t1.identifier &gt; t2.identifier) return 1;
              return 0;
          });
      }
  </code></pre>
  
  <p>Thank you.</p>