Skip to content

Commit ec02be3

Browse files
author
Josh Benahmou
committed
Fix offsetWidth console error
1 parent 8698824 commit ec02be3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/GridLayout.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@
197197
};
198198
},
199199
onWindowResize: function () {
200-
if (this.$refs !== null && this.$refs.item !== null) {
200+
if (this.$refs !== null && this.$refs.item !== null && this.$refs.item !== undefined) {
201201
this.width = this.$refs.item.offsetWidth;
202202
}
203203
},
@@ -252,4 +252,4 @@
252252
},
253253
},
254254
}
255-
</script>
255+
</script>

0 commit comments

Comments
 (0)