vue-router-back-mixin
v0.0.3
Published
Back Mixin for Vue Router
Downloads
10
Maintainers
Readme
Vue Router Back Mixin
Mixin to navigate back with Vue Router
This requires you use vue and vue-router.
Usage
$ npm install vue-router-back-mixin
In component, you can call backMixin_handleBack
method
import BackMixin from `vue-router-back-mixin`
export default {
...
mixins: [BackMixin],
methods() {
goBack() {
this.backMixin_handleBack()
}
}
...
}
You can provide fallbackUrl by passing to backMixin_handleBack
For example:
backMixin_handleBack('/home')