From e4fa652169f14efd0f8ef68131ef0be9c2bf1c67 Mon Sep 17 00:00:00 2001 From: Matan Kushner Date: Thu, 7 Jul 2022 13:31:14 -0400 Subject: [PATCH] chore: use defineConfig to statically type our .vuepress/config --- docs/.vuepress/{config.js => config.ts} | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) rename docs/.vuepress/{config.js => config.ts} (98%) diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.ts similarity index 98% rename from docs/.vuepress/config.js rename to docs/.vuepress/config.ts index 0a425f5d..c35f9ddf 100644 --- a/docs/.vuepress/config.js +++ b/docs/.vuepress/config.ts @@ -1,4 +1,6 @@ -const sidebar = (lang, override = {}) => +import { defineConfig, SidebarConfigArray } from "vuepress/config"; + +const sidebar = (lang, override = {}): SidebarConfigArray => [ "", // "Home", which should always have a override "guide", // README, which should always have a override @@ -23,7 +25,7 @@ const sidebar = (lang, override = {}) => return page in override ? [path, override[page]] : path; }); -module.exports = { +module.exports = defineConfig({ locales: { "/": { lang: "en-US", @@ -331,11 +333,11 @@ module.exports = { }, ], [ - "sitemap", + "vuepress-plugin-sitemap", { hostname: "https://starship.rs", }, ], ["vuepress-plugin-code-copy", true], ], -}; +});