[Intervention] Ignored attempt to cancel a touchmove event when swiping
See original GitHub issueI’m using the vue2-touch-events
plugin to create some “native like” swiping behaviour for a Nuxt JS hybrid app built with Cordova. I’ve implemented an element (positioned absolutely) over the majority of the screen that once swiped on the $router
pushes to a new page.
This has been working fine up until recently where I have noticed an error being fired in my console:
[Intervention] Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted.
I’m not too sure why I’m experiencing this error, and have attempted to revert some things which has made no difference. The code in question is attached:
HTML Vue JS markup
<span
v-touch:swipe.right="swipePrevPage"
v-touch:swipe.left="swipeNextPage"
class="page-swipe-trigger">
</span>
Implemented methods
/**
* Handle page swipe (next page)
*/
swipePrevPage() {
if (this.page && this.id && this.$refs.hasPages[0].innerText === 'true') {
if (this.prevPage != -1) {
this.$router.push('/url/' + this.page + '/' + this.prevPage)
} else {
this.$router.push('/url/' + this.page)
}
}
},
/**
* Handle page swipe (next page)
*/
swipeNextPage() {
if (this.page && this.id && this.$refs.hasPages[0].innerText === 'true') {
if (this.nextPage < parseInt(this.$refs.getPages[0].innerText)) {
this.$router.push('/url/' + this.page + '/' + this.nextPage)
}
}
}
For refernece, I’m using version 2.3.0 of the plugin, and have it configured like this…
import Vue from 'vue'
import Vue2TouchEvents from 'vue2-touch-events'
Vue.use(Vue2TouchEvents, {
touchClass: 'touched',
swipeTolerance: 50
})
If someone could help me with why I’m experiencing this error, the error shows up when trying to swipe.
Issue Analytics
- State:
- Created 3 years ago
- Comments:14 (6 by maintainers)
Top Results From Across the Web
Easy fix for: '[Intervention] Ignored attempt to cancel ... - URIports
Ignored attempt to cancel a touchmove event with cancelable=false - so your browser has ignored the request to cancel an event called touchmove ......
Read more >Touch move getting stuck Ignored attempt to cancel a ...
Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted.
Read more >Solving issue: “[Intervention] Ignored attempt to cancel a ...
Solving issue: “[Intervention] Ignored attempt to cancel a touchmove event with cancelable=false”. This article describes how to solve this warning that ...
Read more >[Intervention] Ignored attempt to cancel a touchmove event when ...
I'm using the vue2-touch-events plugin to create some "native like" swiping behaviour for a Nuxt JS hybrid app built with Cordova.
Read more >三种方法解决[Intervention] Ignored attempt to cancel a ...
[Intervention] Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@ErickPetru I have made this change on
v3.1.1
, you can try this.Nice @jerrybendy, no console error logged anymore.