Jacky Zhao
2023-08-03 5537ca41e0069725e98ef9ad59a2d4dbaa0bd8ae
quartz/plugins/transformers/links.ts
@@ -47,6 +47,7 @@
                  return targetCanonical === fileName
                })
                // only match, just use it
                if (matchingFileNames.length === 1) {
                  const targetSlug = canonicalizeServer(matchingFileNames[0])
                  return (resolveRelative(curSlug, targetSlug) + targetAnchor) as RelativeURL
@@ -99,7 +100,7 @@
                if (!isAbsoluteUrl(node.properties.src)) {
                  const ext = path.extname(node.properties.src)
                  node.properties.src =
                    transformLink(path.join("assets", node.properties.src)) + ext
                    transformLink(joinSegments("assets", node.properties.src)) + ext
                }
              }
            })