Skip to content

Commit 8132106

Browse files
committed
Fix double render when vue lifecycle goes wrong
1 parent f792ac0 commit 8132106

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

index.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ export default defineComponent({
3838
},
3939
methods: {
4040
paint: function () {
41+
if (this.$el.lastChild !== this.$refs._) {
42+
return
43+
}
4144
const _ = this.$el.appendChild(document.createElement('span'))
4245
const _this = this
4346
import(/* webpackMode: "eager" */ 'github-buttons').then(function (module) {

0 commit comments

Comments
 (0)