Remove everything from string after the second - with a single line in Javascript : <p>I want to ensure the language is always extracted from a string, only before the 2nd dash (-)</p>

<p>So</p>

<p><code>en-AU-Option-A</code></p>

<p>becomes</p>

<p><code>en-AU</code></p>

<p>Is this possible with a single line of Javascript?</p>
