Refactor router-view to use scoped slots with dynamic component rendering

This commit is contained in:
2026-01-28 20:23:08 +00:00
parent 0a53b7758f
commit 9f241da3b0

View File

@@ -1,8 +1,10 @@
<template>
<div id="app">
<router-view v-slot="{ Component }">
<Transition name="view-transition" mode="out-in">
<router-view />
<component :is="Component" />
</Transition>
</router-view>
</div>
</template>