chore: add trailingComma

This commit is contained in:
陈嘉涵
2020-01-19 11:57:09 +08:00
parent e841175fe8
commit 389d68884d
269 changed files with 2706 additions and 2702 deletions
+2 -2
View File
@@ -33,7 +33,7 @@ export default {
},
onClickRight() {
this.$toast(this.$t('button'));
}
}
},
},
};
</script>
+5 -5
View File
@@ -40,7 +40,7 @@ function NavBar(
<div
class={[
bem({ fixed: props.fixed }),
{ [BORDER_BOTTOM]: props.border }
{ [BORDER_BOTTOM]: props.border },
]}
style={{ zIndex: props.zIndex }}
{...inherit(ctx)}
@@ -54,7 +54,7 @@ function NavBar(
),
props.leftText && (
<span class={bem('text')}>{props.leftText}</span>
)
),
]}
</div>
<div class={[bem('title'), 'van-ellipsis']}>
@@ -79,12 +79,12 @@ NavBar.props = {
leftArrow: Boolean,
border: {
type: Boolean,
default: true
default: true,
},
zIndex: {
type: Number,
default: 1
}
default: 1,
},
};
export default createComponent<NavBarProps, NavBarEvents>(NavBar);
+4 -4
View File
@@ -5,8 +5,8 @@ test('render left & right slot', () => {
const wrapper = mount(NavBar, {
scopedSlots: {
left: () => 'Custom Left',
right: () => 'Custom Right'
}
right: () => 'Custom Right',
},
});
expect(wrapper).toMatchSnapshot();
@@ -15,8 +15,8 @@ test('render left & right slot', () => {
test('render title slot', () => {
const wrapper = mount(NavBar, {
scopedSlots: {
title: () => 'Custom Title'
}
title: () => 'Custom Title',
},
});
expect(wrapper).toMatchSnapshot();