]> git.ipfire.org Git - thirdparty/vuejs/router.git/commitdiff
docs: add thesemetrics
authorEduardo San Martin Morote <posva13@gmail.com>
Fri, 18 Sep 2020 09:31:20 +0000 (11:31 +0200)
committerEduardo San Martin Morote <posva13@gmail.com>
Fri, 18 Sep 2020 09:31:20 +0000 (11:31 +0200)
docs/.vitepress/config.js

index 51a192f232ad85e3720201fb18506f505eb8c38c..35ad90e973e90a5ff1560bae5f892c96cccd85fb 100644 (file)
@@ -1,4 +1,19 @@
-/** @type {import('vitepress').UserConfig} */
+/** @typedef {import('vitepress').UserConfig} UserConfig */
+
+/** @type {UserConfig['head']} */
+const head = []
+
+if (process.env.NODE_ENV === 'production') {
+  head.push([
+    'script',
+    {
+      src: 'https://unpkg.com/thesemetrics@latest',
+      async: '',
+    },
+  ])
+}
+
+/** @type {UserConfig} */
 const config = {
   lang: 'en-US',
   title: 'Vue Router',
@@ -15,6 +30,7 @@ const config = {
       description: 'El router oficial par Vue.js',
     },
   },
+  head,
   // serviceWorker: true,
   themeConfig: {
     // algolia: {