title: Can't get getTotalLength() from <path>
body: <p>I'm trying to create a SVG path element without appending it to the DOM and just compute its length, but for some reason i'm failing to do so.</p>
  
  <p>After creating a fresh  element and adding a proper length, it doesn't let me call the getTotalLength() function to get its length. It's possible to recreate it by copypasting the following lines on any browser console:</p>
  
  <pre><code>var path = document.createElementNS('SVG', 'path');
  d3.select(path).attr('d', 'M' + 10 + ',' + 10 + 'L' + 75 + ',' + 75);
  path.getTotalLength();
  </code></pre>
  
  <p>This is the error that comes out of the last line of code:</p>
  
  <blockquote>
    <p>Uncaught TypeError: path.getTotalLength is not a function
        at eval</p>
  </blockquote>
  
  <p>I suspect and hope it's something really easy to spot and fix, but i'm short on ideas...</p>