detect-browser-navigation-in-vue-router
v1.1.0
Published
detect browser back/forward navigation button in vue-router
Downloads
313
Readme
detect-browser-navigation-in-vue-router
detect browser back/forward navigation button in vue-router
how to use
install
npm install detect-browser-navigation-in-vue-router
use
import router from './router'
import DetectBrowserNavigationInVueRouter from 'detect-browser-navigation-in-vue-router'
const app = createApp(App)
app.use(router)
const backCallback = () => {
console.log('back')
}
const forwardCallback = () => {
console.log('forward')
}
app.use(DetectBrowserNavigationInVueRouter, { router, backCallback, forwardCallback })