Performance problems
Mobile H5 web page. Can be zoomed by the user in Safari
The solution
Add the following to the index.html template file
Code:
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, Maximum - scale = 1.0, user - scalable = no "/ >
window.onload = function() {
var lastTouchEnd = 0;
document.addEventListener('touchstart'.function(event) {
if (event.touches.length > 1) { event.preventDefault(); }});document.addEventListener('touchend'.function(event) {
var now = (new Date()).getTime();
if (now - lastTouchEnd <= 300) {
event.preventDefault();
}
lastTouchEnd = now;
}, false);
document.addEventListener('gesturestart'.function(event) {
event.preventDefault();
});
document.addEventListener('dblclick'.function(event) { event.preventDefault(); })}Copy the code
To solve this problem see @shimh_ herbal tea link: blog.csdn.net/weixin_3440…