chore: prettier source code
This commit is contained in:
+2
-2
@@ -27,7 +27,7 @@ const [createComponent, bem] = createNamespace('tabs');
|
||||
export default createComponent({
|
||||
mixins: [
|
||||
ParentMixin('vanTabs'),
|
||||
BindEventMixin(function(bind) {
|
||||
BindEventMixin(function (bind) {
|
||||
if (!this.scroller) {
|
||||
this.scroller = getScroller(this.$el);
|
||||
}
|
||||
@@ -231,7 +231,7 @@ export default createComponent({
|
||||
|
||||
// correct the index of active tab
|
||||
setCurrentIndexByName(name) {
|
||||
const matched = this.children.filter(tab => tab.computedName === name);
|
||||
const matched = this.children.filter((tab) => tab.computedName === name);
|
||||
const defaultIndex = (this.children[0] || {}).index || 0;
|
||||
this.setCurrentIndex(matched.length ? matched[0].index : defaultIndex);
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user