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
+10 -10
View File
@@ -10,7 +10,7 @@ function mockOffsetHeight(offsetHeight) {
Object.defineProperty(HTMLElement.prototype, 'offsetHeight', {
get() {
return offsetHeight;
}
},
});
}
@@ -21,7 +21,7 @@ test('custom anchor text', () => {
<van-index-anchor index="A">Title A</van-index-anchor>
<van-index-anchor index="B">Title B</van-index-anchor>
</van-index-bar>
`
`,
});
expect(wrapper).toMatchSnapshot();
@@ -37,8 +37,8 @@ test('click and scroll to anchor', () => {
</van-index-bar>
`,
methods: {
onSelect
}
onSelect,
},
});
const fn = mockScrollIntoView();
@@ -60,8 +60,8 @@ test('touch and scroll to anchor', () => {
</van-index-bar>
`,
methods: {
onSelect
}
onSelect,
},
});
const fn = mockScrollIntoView();
@@ -77,7 +77,7 @@ test('touch and scroll to anchor', () => {
if (index === 3) {
return {
dataset: {}
dataset: {},
};
}
};
@@ -102,7 +102,7 @@ test('scroll and update active anchor', () => {
Element.prototype.getBoundingClientRect = function () {
const { index } = this.dataset;
return {
top: index ? index * 10 : 0
top: index ? index * 10 : 0,
};
};
@@ -121,9 +121,9 @@ test('scroll and update active anchor', () => {
`,
data() {
return {
sticky: false
sticky: false,
};
}
},
});
window.scrollTop = 0;