UNPKG
@scalar/openapi-parser
Version:
latest (0.23.11)
0.23.11
0.23.10
0.23.9
0.23.7
0.23.6
0.23.5
0.23.4
0.23.3
0.23.2
0.23.1
0.23.0
0.22.3
0.22.2
0.22.1
0.21.2
0.21.1
0.21.0
0.20.6
0.20.5
0.20.4
0.20.3
0.20.2
0.20.1
0.20.0
0.19.0
0.18.3
0.18.2
0.18.1
0.18.0
0.17.0
0.16.0
0.15.0
0.14.0
0.13.0
0.12.0
0.11.1
0.11.0
0.10.17
0.10.16
0.10.15
0.10.14
0.10.13
0.10.12
0.10.11
0.10.10
0.10.9
0.10.8
0.10.7
0.10.6
0.10.5
0.10.4
0.10.3
0.10.2
0.10.1
0.10.0
0.9.0
0.8.10
0.8.9
0.8.8
0.8.7
0.8.6
0.8.5
0.8.4
0.8.3
0.8.2
0.8.1
0.7.2
0.7.1
0.7.0
0.6.0
0.5.0
0.4.1
0.4.0
0.3.2
0.3.1
0.3.0
0.2.0
0.1.0
0.0.0
modern OpenAPI parser written in TypeScript
github.com/scalar/scalar
scalar/scalar
@scalar/openapi-parser
/
dist
/
utils
/
betterAjvErrors
/
json
/
utils.js
12 lines
(11 loc)
•
288 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
const getPointers = (dataPath) => { const pointers = dataPath.
split
(
"/"
).slice(
1
);
for
(const
index
in pointers) { pointers[
index
] = pointers[
index
].
split
(
"~1"
).join(
"/"
).
split
(
"~0"
).join(
"~"
); }
return
pointers; }; export { getPointers };
//
# sourceMappingURL=utils.js.map