v-else-if.vdom.js 691 B

12345678910111213141516171819202122232425262728293031323334
  1. ({
  2. type: 'recycle-list',
  3. attr: {
  4. listData: [
  5. { type: 'A' },
  6. { type: 'A' }
  7. ],
  8. templateKey: 'type',
  9. alias: 'item'
  10. },
  11. children: [{
  12. type: 'cell-slot',
  13. attr: { templateType: 'A' },
  14. children: [{
  15. type: 'image',
  16. attr: {
  17. '[[match]]': 'item.sourceA',
  18. src: { '@binding': 'item.sourceA' }
  19. }
  20. }, {
  21. type: 'image',
  22. attr: {
  23. '[[match]]': '!(item.sourceA) && (item.sourceB)',
  24. src: { '@binding': 'item.sourceB' }
  25. }
  26. }, {
  27. type: 'image',
  28. attr: {
  29. '[[match]]': '!(!(item.sourceA) && (item.sourceB))',
  30. src: { '@binding': 'item.placeholder' }
  31. }
  32. }]
  33. }]
  34. })