title: Typescript Sorting based on Enum constants
body: <p>Is it possible to have a list of enums sorted by the order these enums were declared?</p>
  
  <pre><code>enum MyEnum {
      VALUE_1,
      VALUE_3,
      VALUE_2
  }
  </code></pre>
  
  <p>I create a list in a random order</p>
  
  <pre><code>let list = [MyEnum.VALUE_3, MyEnum.VALUE_1, MyEnum.VALUE_2];
  </code></pre>
  
  <p>But it gets ordered as the enum was declared </p>
  
  <pre><code>[MyEnum.VALUE_1, MyEnum.VALUE_3, MyEnum.VALUE_2]
  </code></pre>
  
  <p>PS: I really want to know if typescript orders the list out of the box as we have in Java, without having to order it by my own. If I had to order the list by my own I would be prone to errors if the order ever gets changed.</p>