diff --git a/.gitignore b/.gitignore index fdd8da1a..7c964cfd 100644 --- a/.gitignore +++ b/.gitignore @@ -23,5 +23,6 @@ dist-ssr *.sln *.sw? stats.html -docs/.vitepress/dist -docs/.vitepress/cache/deps/*.* \ No newline at end of file +docs/.vitepress/dist/ +docs/.vitepress/cache/ +docs/.vitepress/.temp/ diff --git a/docs/.vitepress/config.ts b/docs/.vitepress/config.ts index 2df3fd5b..e6bb4e05 100644 --- a/docs/.vitepress/config.ts +++ b/docs/.vitepress/config.ts @@ -1,9 +1,13 @@ import { defineConfig } from 'vitepress' -import Unocss from 'unocss/vite' -import svgLoader from 'vite-svg-loader' import { resolve } from 'pathe' import { templateCompilerOptions } from '@tresjs/core' +const whitelist = [ + 'TresCanvas', + 'TresLeches', + 'TresScene', +] + // https://vitepress.dev/reference/site-config export default defineConfig({ title: 'Cientos', @@ -104,6 +108,7 @@ export default defineConfig({ items: [ { text: 'useTweakpane', link: '/guide/misc/use-tweakpane' }, { text: 'Stats', link: '/guide/misc/stats' }, + { text: 'Html', link: '/guide/misc/html-component' }, { text: 'StatsGl', link: '/guide/misc/stats-gl' }, ], }, @@ -142,6 +147,10 @@ export default defineConfig({ }, }, vue: { - ...templateCompilerOptions, + template: { + compilerOptions: { + isCustomElement: (tag: string) => tag.startsWith('Tres') && !whitelist.includes(tag) || tag === 'primitive', + }, + }, }, }) diff --git a/docs/.vitepress/theme/TresLayout.vue b/docs/.vitepress/theme/TresLayout.vue index c61001ab..e2c36f4f 100644 --- a/docs/.vitepress/theme/TresLayout.vue +++ b/docs/.vitepress/theme/TresLayout.vue @@ -1,8 +1,8 @@