mirror of
https://github.com/youzan/vant.git
synced 2025-10-20 18:54:24 +00:00
fix(Tab): can't match when name is 0 (#5017)
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { createNamespace } from '../utils';
|
||||
import { isDef, createNamespace } from '../utils';
|
||||
import { ChildrenMixin } from '../mixins/relation';
|
||||
import { routeProps } from '../utils/router';
|
||||
|
||||
@@ -22,7 +22,7 @@ export default createComponent({
|
||||
|
||||
computed: {
|
||||
computedName() {
|
||||
return this.name || this.index;
|
||||
return isDef(this.name) ? this.name : this.index;
|
||||
},
|
||||
|
||||
isActive() {
|
||||
|
Reference in New Issue
Block a user