title: Convert CP437 using JavaScript Encoding API in Browser
body: <p>Is there a way to convert CP437 to UTF8 in browser using new <a href="https://developer.mozilla.org/en-US/docs/Web/API/Encoding_API" rel="nofollow noreferrer">Encoding API</a>?</p>
  
  <p>I've tried this:</p>
  
  <pre><code>decoder = new TextDecoder('CP437');
  decoder = new TextDecoder('IBM437');
  </code></pre>
  
  <p>but got error:</p>
  
  <blockquote>
    <p>Uncaught RangeError: Failed to construct 'TextDecoder': The encoding
    label provided ('IBM437') is invalid.
        at :1:11</p>
  </blockquote>
  
  <p>I've also tried with dashes <code>CP-437</code> and <code>IBM-437</code>.</p>
  
  <p>On GNU/Linux I can use iconv, I've found project <a href="https://www.npmjs.com/package/iconv-js" rel="nofollow noreferrer">iconv-js</a>, but it seems it only convert one encoding.</p>
  
  <p>Is compiling iconv to JavaScript using Emscripten the only option?</p>