Refactor svg generation

This is just to help me understand the code, really!
Merge pull request #44 from meshy/refactor-svg

Refactor svg generation
Merge branch 'master' into angular
Remove arrtifact of refactor
Use ng-href for generated urls
Use ng-bind to hide templating code on load

Hm. Now thinking that this might be better as a directive, but it's a start.