• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

thednp / svg-path-commander / 15316798182

29 May 2025 05:13AM UTC coverage: 100.0% (+2.2%) from 97.839%
15316798182

push

github

thednp
update deps, workflows, tests, bump

729 of 729 branches covered (100.0%)

Branch coverage included in aggregate %.

1400 of 1400 relevant lines covered (100.0%)

3288.25 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

100.0
/src/convert/pathToRelative.ts
1
import type { PathArray, RelativeArray } from "../types";
2
import parsePathString from "../parser/parsePathString";
3
import iterate from "../process/iterate";
4
import relativizeSegment from "../process/relativizeSegment";
5

6
/**
7
 * Parses a path string value or object and returns an array
8
 * of segments, all converted to relative values.
9
 *
10
 * @param pathInput the path string | object
11
 * @returns the resulted `pathArray` with relative values
12
 */
13
const pathToRelative = (pathInput: string | PathArray): RelativeArray => {
2✔
14
  const path = parsePathString(pathInput);
17✔
15

16
  return iterate<RelativeArray>(path, relativizeSegment);
17✔
17
};
18
export default pathToRelative;
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc