We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9dae6a3 commit 9d4c57bCopy full SHA for 9d4c57b
1 file changed
docs/.vitepress/config.js
@@ -154,9 +154,12 @@ function buildProjectNavItems() {
154
}
155
156
function buildEditLink({ filePath }) {
157
- const repoUrl = "https://github.com/BlueLua";
158
const [repo, ...rest] = filePath.split("/");
159
- return `${repoUrl}/${repo}/edit/main/docs/${rest.join("/")}`;
+ const isApi = rest[0] === "api";
+ const target = isApi
160
+ ? `types/${rest.slice(1).join("/").replace(/\.md$/, ".d.lua")}`
161
+ : `docs/${rest.join("/")}`;
162
+ return `https://github.com/BlueLua/${repo}/edit/main/${target}`;
163
164
165
function filterSearchResult(result) {
0 commit comments