|
|
@@ -77,7 +77,7 @@ export default {
|
|
77
|
77
|
this.$store.commit(`CLEAR_${uppercaseType}`)
|
|
78
|
78
|
this.$store.commit(`${uppercaseType}_LOADED`)
|
|
79
|
79
|
},
|
|
80
|
|
- loadMorePosts() {
|
|
|
80
|
+ async loadMorePosts() {
|
|
81
|
81
|
console.log('trying to load for: ', this.$route)
|
|
82
|
82
|
const type = typeFromRoute(this.$route)
|
|
83
|
83
|
if(!type) return console.warn(`type: ${type} not found...`)
|
|
|
@@ -150,7 +150,7 @@ export default {
|
|
150
|
150
|
if(!footerEl) return
|
|
151
|
151
|
const onIntersect = entries => {
|
|
152
|
152
|
if(this.isFetching) return
|
|
153
|
|
-
|
|
|
153
|
+
|
|
154
|
154
|
this.isFetching = true
|
|
155
|
155
|
entries.forEach(({ target, isIntersecting }) => {
|
|
156
|
156
|
if (!isIntersecting) return
|