How to use the carbon-components.Pagination.create function in carbon-components

To help you get started, we’ve selected a few carbon-components examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github CarvueJS / carbon-components-vue / components / CaPagination / CaPagination.vue View on Github external
mounted() {
    this.pagination = Pagination.create(this.$el);
    this.pagination.element.addEventListener('pageChange', (e) => {
      if (e.detail.direction === 'forward') {
        this.value > 1 ? this.$emit('input', this.value - 1) : '';
      } else {
        this.$emit('input', this.value + 1);
      }
    });
  },
  methods: {