Refactoring

This commit is contained in:
syuilo 2017-05-18 14:34:13 +09:00
parent 7c7e824070
commit 88041dbd94

View file

@ -37,7 +37,13 @@ const [head] = document.getElementsByTagName('head');
if (isMobile) {
const meta = document.createElement('meta');
meta.setAttribute('name', 'viewport');
meta.setAttribute('content', 'width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no');
meta.setAttribute('content', [
['width', 'device-width'],
['initial-scale', '1'],
['minimum-scale', '1'],
['maximum-scale', '1'],
['user-scalable', 'no']
].map(x => x.join('=')).join(','));
head.appendChild(meta);
}