title: JavaScript String.split on a string literal to produce an array
body: <p>I've seen a few javascript programmers use this pattern to produce an array:</p>
  
  <pre><code>"test,one,two,three".split(','); // =&gt; ["test", "one", "two", "three"]
  </code></pre>
  
  <p>They're not splitting user input or some variable holding a string value, they're splitting a hard-coded string literal to produce an array. In all of the cases I've seen a line like the above it would seem that it's perfectly reasonable to just use an array literal without relying on <code>split</code> to create an array from a string. Are there any reasons that the above pattern for creating an array makes sense, or is somehow more efficient than simply using an array literal?</p>