Buenos días desarrolladores. Estoy trabajando en esta aplicación IONIC + VUE, específicamente en un popover con alguna funcionalidad, pero por alguna razón el popover tiene un comportamiento extraño, porque una vez que está abierto y hago clic para cerrarlo, la primera vez que el modal aún persiste y arroja este error:
Uncaught RangeError: Maximum call stack size exceeded at Object.ownKeys at hasBinary (is-binary.js:48) at hasBinary (is-binary.js:49) at hasBinary (is-binary.js:49) at hasBinary (is-binary.js:49) at hasBinary (is-binary.js:49) at hasBinary (is-binary.js:49) at hasBinary (is-binary.js:49) at hasBinary (is-binary.js:49) at hasBinary (is-binary.js:49)luego, en el segundo, haga clic en cerrar.
Déjame darte un poco de historia sobre lo que hice.
Por lo tanto, aquí la plantilla con el botón que activa un método en vuex que hace algunas cosas, y también ha incluido el método que cierra el modal (closeOpenedPopOver())
NOTA: si no pongo la acción del despachador en vuex, el modal se cierra correctamente
TEMPLATE <ion-content> <ion-row> <ion-col size="6"></ion-col> <ion-button @click="stopModal()"> Stop </ion-button> </ion-row> </ion-content> METHOD methods: { ...mapActions(["someAction"]), stopModal(): void { this.$store.dispatch("someAction", { dataPopOver: 'something sent', }); this.closeOpenedPopOver(); }, //method that set an action in vuex and also has the method that // closes the modal closeOpenedPopOver(): void { popoverController.dismiss(); }, //modal closer }, VUEX someAction({ dispatch }, payload) { commit(""); dispatch("otherAction"); socket.emit("something", payload); }, //This first action emit something through sockets IO and also call other action in charge of closing doing other stuffs otherAction({ state, commit }) { ......some other stuffs... },¿Alguna idea de por qué sucede esto?
Gracias de antemano y Feliz Nuevo 2022