首页瀑布流

This commit is contained in:
luJianJun 2023-07-31 17:47:39 +08:00
parent d024db53f4
commit 1c3bf8e9c5
2 changed files with 10 additions and 2 deletions

View File

@ -99,7 +99,7 @@
</template>
<script setup>
import { defineProps, reactive } from 'vue'
import { defineProps, reactive,watchEffect } from 'vue'
import store from '../../store/index';
import { useRouter } from 'vue-router'
const props = defineProps({
@ -134,6 +134,9 @@ let watchAdv = () => {
}
}
watchEffect(()=>{
itemData = props.data
})
</script>
<style scoped>
.pos-r {

View File

@ -256,9 +256,14 @@ let getRecommendList = () => {
loadText.value = '到底了'
}
nextTick(() => {
console.log(listMasonryInstance)
console.log(1)
listMasonryInstance.reloadItems();
listMasonryInstance.layout();
setTimeout(() => {
console.log(3)
listMasonryInstance.reloadItems();
listMasonryInstance.layout();
}, 600)
})
} else {
ElMessage({