summaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
authorwout <wout@impinc.co.uk>2013-03-24 19:50:07 +0100
committerwout <wout@impinc.co.uk>2013-03-24 19:50:07 +0100
commit20e9f674cb11d0f856baf7e05517cbebda31fdb8 (patch)
tree0fbf541cbc326e2caeaac996fc549a9b2e4e281b /README.md
parent7c3b0e675fcc3ff72a6ce29124e8367b625391aa (diff)
downloadsvg.js-20e9f674cb11d0f856baf7e05517cbebda31fdb8.tar.gz
svg.js-20e9f674cb11d0f856baf7e05517cbebda31fdb8.zip
Updated README
Diffstat (limited to 'README.md')
-rw-r--r--README.md7
1 files changed, 7 insertions, 0 deletions
diff --git a/README.md b/README.md
index 25cf24e..85d3908 100644
--- a/README.md
+++ b/README.md
@@ -135,6 +135,13 @@ var polyline = draw.polyline('10,20 30,40 50,60')
Polyline strings consist of a list of points separated by spaces: `x,y x,y x,y`.
+As an alternative an array of points will work as well:
+
+```javascript
+// polyline([[x,y], [x,y], [x,y]])
+var polyline = draw.polyline([[10,20], [30,40], [50,60]])
+```
+
### Polygon
The polygon element, unlike the polyline element, defines a closed shape consisting of a set of connected straight line segments: