Skip to content

Commit

Permalink
adjusted aliases in vite config
Browse files Browse the repository at this point in the history
  • Loading branch information
Tinoooo committed Jan 2, 2025
1 parent aa4ffcd commit ff69040
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions docs/.vitepress/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,7 @@ export default defineConfig({
},
resolve: {
alias: {
'@tresjs/post-processing': resolve(__dirname, '../../src/core/three'),
'@tresjs/post-processing/pmndrs': resolve(__dirname, '../../src/core/pmndrs'),
'@tresjs/post-processing': resolve(__dirname, '../../src'),
},
dedupe: ['three', '@tresjs/core'],
},
Expand Down
4 changes: 2 additions & 2 deletions docs/.vitepress/theme/composables/useRouteDisposal.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import type { EffectComposer } from '@tresjs/post-processing/pmndrs'
import type { EffectComposerPmdrs } from '@tresjs/post-processing'
import { useRouter } from 'vitepress'
import { ref, watch } from 'vue'

export function useRouteDisposal() {
const router = useRouter()

const effectComposer = ref<InstanceType<typeof EffectComposer> | null>(null)
const effectComposer = ref<InstanceType<typeof EffectComposerPmdrs> | null>(null)

watch(() => router.route.data.relativePath, () => {
effectComposer.value?.composer.dispose()
Expand Down

0 comments on commit ff69040

Please sign in to comment.