Skip to content

Commit 5a17846

Browse files
committed
Fix the bug that cannot display no-results and no-more prompt
1 parent 5ddbfb3 commit 5a17846

File tree

2 files changed

+6
-9
lines changed

2 files changed

+6
-9
lines changed

example/index.html

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,6 @@
3636
distance: 100,
3737
list: []
3838
},
39-
ready: function () {
40-
for (var i = 0; i < 50; i++) {
41-
this.list.push(i + 1);
42-
}
43-
},
4439
methods: {
4540
onInfinite: function () {
4641
setTimeout(function () {

src/components/InfiniteLoading.vue

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
<template>
2-
<div class="infinite-loading-container" v-show="isLoading">
3-
<slot name="spinner">
4-
<i :class="spinnerType"></i>
5-
</slot>
2+
<div class="infinite-loading-container">
3+
<div v-show="isLoading">
4+
<slot name="spinner">
5+
<i :class="spinnerType"></i>
6+
</slot>
7+
</div>
68
<div class="infinite-status-prompt" v-show="!isLoading && isComplete && isFirstLoad">
79
<slot name="no-results">No results :(</slot>
810
</div>

0 commit comments

Comments
 (0)