UNPKG
malebranche
Version:
latest (2.1.0)
2.1.0
2.0.0
1.4.6
1.4.5
1.4.4
1.4.3
1.4.2
1.4.1
1.4.0
1.3.0
1.2.0
1.1.4
1.1.3
1.1.2
1.1.1
1.1.0
1.0.1
1.0.0
Converts clip path coordinates from absolute to fractional units between 0 and 1.
malebranche
/
src
/
points-parser.js
7 lines
(6 loc)
•
181 B
JavaScript
View Raw
1
2
3
4
5
6
7
function
arrayFromPoints
(
pointsString
) {
return
pointsString.
trim
().
split
(
/[ ,]+/
).
map
(
function
(
el
) {
return
parseInt
(el,
10
); }); }
exports
.
arrayFromPoints
= arrayFromPoints;