File tree Expand file tree Collapse file tree 3 files changed +180
-180
lines changed Expand file tree Collapse file tree 3 files changed +180
-180
lines changed Original file line number Diff line number Diff line change @@ -2,11 +2,11 @@ export * from './dedupeHead.js'
2
2
export * from './ensureLeadingSlash.js'
3
3
export * from './ensureEndingSlash.js'
4
4
export * from './formatDateString.js'
5
+ export * from './inferRoutePath.js'
5
6
export * from './isLinkExternal.js'
6
7
export * from './isLinkHttp.js'
7
8
export * from './isLinkWithProtocol.js'
8
9
export * from './isPlainObject.js'
9
- export * from './inferRoutePath.js'
10
10
export * from './normalizeRoutePath.js'
11
11
export * from './omit.js'
12
12
export * from './removeEndingSlash.js'
Original file line number Diff line number Diff line change
1
+ /**
2
+ * Infer route path according to the given (markdown file) path
3
+ */
1
4
export const inferRoutePath = ( path : string ) : string => {
2
5
// if the pathname is empty or ends with `/`, return as is
3
6
if ( ! path || path . endsWith ( '/' ) ) return path
You can’t perform that action at this time.
0 commit comments