perf: tree-shake dependencies from server (#1647)

This commit is contained in:
Daniel Roe 2023-02-06 01:34:50 -08:00 committed by GitHub
parent 357dff2140
commit 6dc38c7d8e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 90 additions and 19 deletions

View file

@ -21,7 +21,7 @@ const { modelValue } = defineModel<{
const target = ref()
const animateTimeout = useTimeout(10)
const reduceMotion = useReducedMotion()
const reduceMotion = process.server ? ref(false) : useReducedMotion()
const canAnimate = computed(() => !reduceMotion.value && animateTimeout.value)