Cordova, Windows 10

Preventing Pinch-Zoom in Cordova on Windows 10 Mobile | Cordova

One of the most obvious ways to spot a Cordova app is a pinch-zoom inside the app. On Android and iOS you can use meta-tags and CSS to disable the pinch-zoom and over scroll. But for some reason I couldn’t get it disabled on Windows 10 mobile.

The Solution

I’ve been looking everywhere for the solution. And after a long search it turned out to be very easy. Just add the following CSS to your app:

html {
    touch-action: none;
}

There used to be a Microsoft vender specific version of this, but the vender part is dropped and it’s now according to the W3C standard.

The Complete Web Developer Course 2.0

The Complete Node.js Developer Course (2nd Edition)

2 comments

Leave a Reply

Seo wordpress plugin by www.seowizard.org.
%d bloggers like this: