123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- import { defineConfig } from 'vitepress'
- import { resolve } from 'pathe'
- export const sharedConfig = defineConfig({
- title: 'TresJS',
- description: 'Declarative ThreeJS using Vue Components',
- head: [
- ['link', { rel: 'icon', type: 'image/svg', href: '/favicon.svg' }],
- ['meta', { name: 'theme-color', content: '#82DBC5' }],
- ['meta', { name: 'twitter:card', content: 'summary_large_image' }],
- ['meta', { name: 'twitter:site', content: '@tresjs_dev' }],
- ['meta', { name: 'twitter:creator', content: '@tresjs_dev' }],
- ['meta', { property: 'og:type', content: 'website' }],
- ['meta', { property: 'og:site_name', content: 'TresJS' }],
- [
- 'meta',
- {
- property: 'og:image',
- content: 'https://repository-images.githubusercontent.com/571314349/10996566-7f70-473b-a8e5-4e56fc0ca850',
- },
- ],
- [
- 'meta',
- {
- property: 'twitter:image',
- content: 'https://repository-images.githubusercontent.com/571314349/10996566-7f70-473b-a8e5-4e56fc0ca850',
- },
- ],
- ['script', { defer: 'true', 'data-domain': 'tresjs.org', src: 'https://plausible.io/js/script.js' }],
- ],
- themeConfig: {
- logo: '/logo.svg',
- socialLinks: [
- { icon: 'github', link: 'https://github.com/tresjs/tres' },
- { icon: 'x', link: 'https://twitter.com/tresjs_dev' },
- { icon: 'discord', link: 'https://discord.gg/UCr96AQmWn' },
- ],
- },
- vite: {
- optimizeDeps: {
- exclude: ['vitepress'],
- include: ['three'],
- },
- server: {
- hmr: {
- overlay: false,
- },
- },
- resolve: {
- alias: {
- '@tresjs/core': resolve(__dirname, '../../../dist/tres.js'),
- },
- dedupe: ['@tresjs/cientos', 'three'],
- },
- },
- vue: {
- template: {
- compilerOptions: {
- isCustomElement: tag => tag.startsWith('Tres') && tag !== 'TresCanvas',
- },
- },
- },
- })
|