We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent aefe95d commit fa424aaCopy full SHA for fa424aa
src/lib.js
@@ -586,7 +586,7 @@ export function createSmoothPath(points) {
586
const cpe = controlPoint(point, a[i - 1], a[i + 1], true);
587
return `C ${cps.x},${cps.y} ${cpe.x},${cpe.y} ${point.x},${point.y}`;
588
}
589
- const d = points.reduce((acc, point, i, a) => i === 0
+ const d = points.filter(p => !!p).reduce((acc, point, i, a) => i === 0
590
? `${point.x},${point.y} `
591
: `${acc} ${bezierCommand(point, i, a)} `
592
, '');
0 commit comments