Refactor
This commit is contained in:
parent
09397f3f65
commit
04bc84358d
1 changed files with 6 additions and 7 deletions
|
@ -45,13 +45,12 @@
|
|||
if (isMobile) {
|
||||
const meta = document.createElement('meta');
|
||||
meta.setAttribute('name', 'viewport');
|
||||
meta.setAttribute('content', Object.entries({
|
||||
'width': 'device-width',
|
||||
'initial-scale': '1',
|
||||
'minimum-scale': '1',
|
||||
'maximum-scale': '1',
|
||||
'user-scalable': 'no'
|
||||
}).map(x => x.join('=')).join(','));
|
||||
meta.setAttribute('content',
|
||||
'width=device-width,' +
|
||||
'initial-scale=1,' +
|
||||
'minimum-scale=1,' +
|
||||
'maximum-scale=1,' +
|
||||
'user-scalable=no');
|
||||
head.appendChild(meta);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue