Ionic Vue: VueJsPaginate not showing

265 Views Asked by At

I am developing an app which has a list of objects that I want to paginate. I found vuejs-paginate plugin but I can't make it work in my view.

After installing it via npm and importing in the view, its tag is in fact in the HTML skeleton of the page, but it shows nothing. No error is displayed in the console either, only this Vue warning:

[Vue warn]: Failed to resolve component: paginate

Might it be a problem with the import? Could you help me?

I attach part of my code so you can see how I've declared it.

<template>
  <ion-page>
    <ion-content>
      <paginate
        :pageCount="10"
        :containerClass="'pagination'"
        :clickHandler="clickCallback"
      >
      </paginate>
    </ion-content>
  </ion-page>
</template>

<script>
import {
  IonContent,
  IonPage,
} from "@ionic/vue";

import { defineComponent } from "vue";
import { VuejsPaginate } from "vuejs-paginate";

export default defineComponent({
  name: "Gestion",
  components: {
    'paginate': VuejsPaginate,
  },
  methods: {
    clickCallback: function(page) {
      console.log(page)
  },
});
</script>

This has also happened to me when trying to import other "external" components. Could it be a problem related to Ionic?

Thank you in advance!

0

There are 0 best solutions below