diff --git a/src/helpers/linkUtils.js b/src/helpers/linkUtils.js index 189de0c..aabcc17 100644 --- a/src/helpers/linkUtils.js +++ b/src/helpers/linkUtils.js @@ -36,7 +36,9 @@ function getGraph(data) { let stemURLs = {}; let homeAlias = "/"; (data.collections.note || []).forEach((v, idx) => { - let fpath = v.filePathStem.replace("/notes/", ""); + let fpath = v.data["dg-path"] + ? v.data["dg-path"].split(".md")[0] + : v.filePathStem.replace("/notes/", ""); let parts = fpath.split("/"); let group = "none"; if (parts.length >= 3) {