udpated README.md

This commit is contained in:
Klemek
2019-07-15 09:59:13 +02:00
parent d6cf2703d8
commit 18cd4e8855
7 changed files with 92 additions and 18 deletions
+23
View File
@@ -0,0 +1,23 @@
const fs = require('fs');
const rendering = require('./src/rendering')({
'beautify': false,
'scale': 0.05,
'h-spacing': 1,
});
['default', 'double', 'line'].forEach(type => {
fs.writeFileSync(`preview/link-${type}.svg`, rendering.toXML({
'g': {
'_attributes': {
'transform': 'translate(0 -128)'
},
'path': {
'_attributes': {
'd': rendering.getLinkPath(type, 2)
}
}
}
}, {w: 1024, h: 256}), {encoding: 'utf-8'});
});