Can iview add events to router.js?

as shown above, I want to trigger an event when the user clicks X when the page is closed. Where should this event be written? Is it written and added in router.js?
for example:
{path: "message",
title:" message Center",
name: "message_index",
component: () = > import (" @ / views/message/message.vue")
}
or is it added somewhere else? Ask the great god to guide ~

Apr.02,2021

modify the source code / src/view/main/main.vue

handleCloseTag

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e3f39b-43b72.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e3f39b-43b72.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?