Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid prop: custom validator check failed for prop "data". #26

Open
Lingouzi opened this issue Nov 12, 2021 · 1 comment
Open

Invalid prop: custom validator check failed for prop "data". #26

Lingouzi opened this issue Nov 12, 2021 · 1 comment

Comments

@Lingouzi
Copy link

vue3 测试代码

<template>
  <div id="app">
    <WaterFall :data="list" width="400px" gap="20px" :delay="false">
      <template #default="item">
        <div class="card">
          {{ item }}
        </div>
      </template>
    </WaterFall>
  </div>
</template>

<script>
  import {ref} from "vue";
  import WaterFall from 'kuan-vue-waterfall'

  export default {
    name: 'App',
    components: {WaterFall},
    setup() {
      const list2 = ref([
        {name: 'hello'}
      ])


      function getNext() {
        console.log('get next...')
        list2.value.push({
          name: 'time ' + new Date().getTime()
        })
      }

      setTimeout(() => {
        getNext()
      }, 2000)

      return {
        list2,
        getNext
      }
    },
    data() {
      return {
        list: [{name: 'name'}]
      }
    }
  }
</script>
@leiyangs
Copy link

我也遇到了这个问题,导致后面加载的数据,在item中拿不到,有解决方法吗

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants