local and global graph

This commit is contained in:
Jacky Zhao
2023-06-18 10:47:07 -07:00
parent 8bfee04c8c
commit c4cf0dcb02
23 changed files with 1288 additions and 110 deletions

View File

@ -13,10 +13,6 @@ export function trimPathSuffix(fp: string): string {
cleanPath = cleanPath.slice(0, -"index".length)
}
if (cleanPath === "") {
cleanPath = "./"
}
return cleanPath + anchor
}
@ -36,7 +32,7 @@ export function slugify(s: string): string {
export function resolveToRoot(slug: string): string {
let fp = trimPathSuffix(slug)
if (fp === "./") {
if (fp === "") {
return "."
}