title: Convert SVG Path to Absolute Commands
body: <p>Given an SVG Path element, how can I convert all path commands into absolute coordinates? For example, convert this path:</p>
  
  <pre><code>&lt;path d="M17,42 l100,0 v100 h-100 z"/&gt;
  </code></pre>
  
  <p>into this equivalent path:</p>
  
  <pre><code>&lt;path d="M17,42 L117,42 V142 H17 Z"/&gt;
  </code></pre>
  
  <p><em>This question was motivated by <a href="https://superuser.com/questions/399980/illustrator-svg-how-can-i-use-only-absolute-coordinates">this question</a>.</em></p>