2
0

attrs.vue 575 B

1234567891011121314151617181920212223
  1. <template>
  2. <recycle-list for="item in longList" switch="type">
  3. <cell-slot case="A">
  4. <image resize="cover" :src="item.source">
  5. <text lines="3" v-bind:count="item.count"></text>
  6. </cell-slot>
  7. </recycle-list>
  8. </template>
  9. <script>
  10. module.exports = {
  11. data () {
  12. return {
  13. longList: [
  14. { type: 'A', count: 1, source: 'http://whatever.com/x.png' },
  15. { type: 'A', count: 2, source: 'http://whatever.com/y.png' },
  16. { type: 'A', count: 3, source: 'http://whatever.com/z.png' }
  17. ]
  18. }
  19. }
  20. }
  21. </script>