Menu: delay addItem so it is after old instances's remoteItem when re-render (#11036)

This commit is contained in:
杨奕 2018-05-07 12:13:23 +08:00 committed by GitHub
parent 7409be8ce1
commit 897f20683f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -97,10 +97,10 @@
if (!this.disabled) { if (!this.disabled) {
this.dispatch('ElMenu', 'item-click', this); this.dispatch('ElMenu', 'item-click', this);
this.$emit('click', this); this.$emit('click', this);
}; }
} }
}, },
created() { mounted() {
this.parentMenu.addItem(this); this.parentMenu.addItem(this);
this.rootMenu.addItem(this); this.rootMenu.addItem(this);
}, },