chore(Tab): rename onShow to init (#6488)

This commit is contained in:
neverland 2020-06-08 19:44:27 +08:00 committed by GitHub
parent ab84662ecf
commit 713c8e0101
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -166,11 +166,11 @@ export default createComponent({
}, },
mounted() { mounted() {
this.onShow(); this.init();
}, },
activated() { activated() {
this.onShow(); this.init();
this.setLine(); this.setLine();
}, },
@ -180,7 +180,7 @@ export default createComponent({
this.setLine(); this.setLine();
}, },
onShow() { init() {
this.$nextTick(() => { this.$nextTick(() => {
this.inited = true; this.inited = true;
this.tabHeight = getVisibleHeight(this.$refs.wrap); this.tabHeight = getVisibleHeight(this.$refs.wrap);