فهرست منبع

docs: added `templateCompilerOptions` to docs

alvarosabu 1 سال پیش
والد
کامیت
ca371143a7
1فایلهای تغییر یافته به همراه2 افزوده شده و 11 حذف شده
  1. 2 11
      docs/vite.config.ts

+ 2 - 11
docs/vite.config.ts

@@ -2,12 +2,7 @@ import { defineConfig } from 'vite'
 import Unocss from 'unocss/vite'
 import svgLoader from 'vite-svg-loader'
 import Components from 'unplugin-vue-components/vite'
-
-const whitelist = [
-  'TresCanvas',
-  'TresLeches',
-  'TresScene',
-]
+import { templateCompilerOptions } from '@tresjs/core'
 
 export default defineConfig({
   plugins: [
@@ -23,10 +18,6 @@ export default defineConfig({
     }),
   ],
   vue: {
-    template: {
-      compilerOptions: {
-        isCustomElement: (tag: string) => tag.startsWith('Tres') && !whitelist.includes(tag) || tag === 'primitive',
-      },
-    },
+    ...templateCompilerOptions
   }
 })