fix. 서버 미들웨어, 미들웨어 수정
This commit is contained in:
10
layers/plugins/router-state.client.ts
Normal file
10
layers/plugins/router-state.client.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
export default defineNuxtPlugin(() => {
|
||||
const router = useRouter()
|
||||
const modalStore = useModalStore()
|
||||
|
||||
router.beforeEach((to, from) => {
|
||||
if (to.path !== from.path) {
|
||||
modalStore.handleResetModalAll()
|
||||
}
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user