infinite loading for search results

This commit is contained in:
2020-07-18 15:03:19 +02:00
parent fb4cb676ac
commit f8e04edb86
2 changed files with 44 additions and 8 deletions
+8 -2
View File
@@ -16,6 +16,9 @@
<li v-for="result in results" :key="result.uuid" class="result">
<ResultItem :result="result" />
</li>
<infinite-loading
@infinite="nextResultsBatch"
/>
</ul>
</div>
</section>
@@ -34,7 +37,7 @@
<script>
import ResultItem from '../Content/ResultItem'
import { mapState } from 'vuex'
import { mapState, mapActions } from 'vuex'
export default {
name: 'Results',
@@ -56,7 +59,10 @@ export default {
close () {
console.log('clicked on close results')
this.opened = false
}
},
...mapActions({
nextResultsBatch: 'Search/nextResultsBatch'
})
}
}
</script>