Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

123456789101112131415161718192021222324252627282930
  1. const pidMixin = {
  2. props: {
  3. pid: {
  4. type: Number,
  5. required: true,
  6. validator: prop => typeof prop === 'number' || prop === null
  7. },
  8. }
  9. }
  10. const cardMixin = {
  11. data: () => ({
  12. cards: [],
  13. loading: true,
  14. }),
  15. watch: {
  16. /** Fetch the queue if pid changes */
  17. pid() { this.getCards() },
  18. },
  19. async created() {
  20. await this.getCards()
  21. },
  22. methods: {
  23. _reformat(data, mapCb) {
  24. return data.map(mapCb)
  25. }
  26. }
  27. }
  28. export { pidMixin, cardMixin }