layout.hbs
6.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>{{title}}</title>
<meta name="keywords" content="{{keywords}}">
<meta name="description" content="{{description}}">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no">
<meta http-equiv="cleartype" content="on">
<meta name="apple-mobile-web-app-status-bar-style" content="black" />
<meta content="telephone=no" name="format-detection" />
<meta content="email=no" name="format-detection" />
<meta name="referrer" content="always">
{{# cononical}}
<link rel="cononical" href="{{currentHref}}">
{{/ cononical}}
{{#if miphtml}}
<link rel="miphtml" href="{{miphtml}}">
{{/if}}
{{#dnsPrefetch.hosts}}
<link rel="dns-prefetch" href="{{this}}">
{{/dnsPrefetch.hosts}}
{{!-- Android机器页面不再受到用户字体缩放强制改变大小 'http://m.blog.csdn.net/article/details?id=51275080' --}}
<script type="text/javascript">
var isWechat = /micromessenger/i.test(navigator.userAgent || '');
if (isWechat) {
document.title =document.title.replace(' | Yoho!Buy有货 | 潮流购物逛不停', '');
(function(){function setWechatSize(){if(typeof WeixinJSBridge!=="undefined"&&WeixinJSBridge.invoke){WeixinJSBridge.invoke("setFontSizeCallback",{fontSize:0},function(){})}}if(typeof WeixinJSBridge!=="undefined"){setTimeout(setWechatSize,0)}else{document.addEventListener("WeixinJSBridgeReady",function(){setTimeout(setWechatSize,0)})};}());
}
</script>
{{#if width750}}
<script type="text/javascript">
(function(d,c){var e=d.documentElement,a="orientationchange" in window?"orientationchange":"resize",b=function(){var f=e.clientWidth;if(!f){return}if(f>=750){e.style.fontSize="40px"}else{e.style.fontSize=40*(f/750)+"px"}};if(!d.addEventListener){return}b();c.addEventListener(a,b,false);d.addEventListener("DOMContentLoaded",b,false)})(document,window);
</script>
{{^}}
<script type="text/javascript">
(function(d,c){var e=d.documentElement,a="orientationchange" in window?"orientationchange":"resize",b=function(){var f=e.clientWidth;if(!f){return}if(f>=640){e.style.fontSize="40px"}else{e.style.fontSize=40*(f/640)+"px"}};if(!d.addEventListener){return}b();c.addEventListener(a,b,false);d.addEventListener("DOMContentLoaded",b,false)})(document,window);
</script>
{{/if}}
{{#unless devEnv}}
{{#if localCss }}
<link rel="stylesheet" media="all" href="//cdn.yoho.cn/m-yohobuy-node/{{version}}/common.css?t={{startTime}}">
{{/if}}
{{#if isFeature}}
<link rel="stylesheet" media="all" href="//cdn.yoho.cn/m-yohobuy-node/{{version}}/feature.css?t={{startTime}}">
{{else}}
{{#ifor localCss vue}}
<link rel="stylesheet" media="all" href="//cdn.yoho.cn/m-yohobuy-node/{{version}}/{{module}}.{{page}}.css?t={{startTime}}">
{{^}}
<link rel="stylesheet" media="all" href="//cdn.yoho.cn/m-yohobuy-node/{{version}}/index.css?t={{startTime}}">
{{/ifor}}
{{/if}}
{{/unless}}
<link rel="apple-touch-icon-precomposed" href="http://static.yohobuy.com/m/v1/img/touch/apple-touch-icon-144x144-precomposed-new.png">
<link rel="apple-touch-startup-image" sizes="640x920" href="http://static.yohobuy.com/m/v1/img/startup/startup-retina.png" media="screen and (max-device-width: 480px) and (-webkit-min-device-pixel-ratio: 2)">
<link rel="apple-touch-startup-image" sizes="320x460" href="http://static.yohobuy.com/m/v1/img/startup/startup.png" media="screen and (max-device-width: 320)">
</head>
<body class="{{pageStyle}} {{#if isWechat}}wechat-body{{/if}} {{#if width750}}width750{{/if}} {{#if isPassportPage}}passport-body{{/if}} {{#if isStarIndexPage}}star-index-bg{{/if}} {{#if isStarDetailPage}}star-class-body{{/if}} {{#if isInstallmentPage}}installment-body{{/if}}">
<div class="main-wrap" id="main-wrap" {{#if appPath}}data-apppath='{{{appPath}}}'{{/if}}>
{{#if systemUpdate}}
{{> updata}}
{{/if}}
{{#if showHeader}}
{{#unless isApp}}
{{> header}}
{{/unless}}
{{/if}}
{{{body}}}
{{#unless isApp}}
{{> footer}}
{{/unless}}
</div>
{{> download-app}}
{{#ifand isProduction wap.open.bughd}}
<script type="text/javascript" src="//cdn.yoho.cn/tool/bj-report-tryjs.min.js?t={{startTime}}" crossOrigin="anonymous"></script>
<script type="text/javascript">
if (BJ_REPORT && BJ_REPORT.init) {
BJ_REPORT.init({
id: 2,
url: "//badjs.yoho.cn/badjs",
ignore: [/Script error/i],
offlineLog: false,
offlineLogAuto: false
});
}
</script>
{{/ifand}}
{{#wechatShare}}
<script type="text/javascript" src="//res.wx.qq.com/open/js/jweixin-1.1.0.js"></script>
{{/wechatShare}}
{{#if devEnv}}
<script>var STATIC_RESOURCE_PATH = '//{{devHost}}:5001';</script>
<script src="//{{devHost}}:5001/libs.js"></script>
{{!--开发环境的CSS需要hot reload, 所以使用 JS 方式加载--}}
{{#if localCss}}
<script src="//{{devHost}}:5001/common.js"></script>
{{else}}
<script src="//{{devHost}}:5001/index.js"></script>
{{/if}} {{#if isFeature}}
<script src="//{{devHost}}:5001/feature.js"></script>
{{/if}}
<script src="//{{devHost}}:5001/{{module}}.{{page}}.js"></script>
{{^}}
<script>var STATIC_RESOURCE_PATH = '//cdn.yoho.cn/m-yohobuy-node/assets';</script>
<script src="//cdn.yoho.cn/m-yohobuy-node/{{version}}/libs.js?t={{startTime}}"></script>
{{#ifand isProduction wap.open.bughd}}
<script>
if (BJ_REPORT && BJ_REPORT.tryJs) {
BJ_REPORT.tryJs().spyAll();
}
</script>
{{/ifand}}
<script src="//cdn.yoho.cn/m-yohobuy-node/{{version}}/{{module}}.{{page}}.js?t={{startTime}}"></script>
{{/if}}
{{#loadJs}}
<script type="text/javascript" src="{{src}}"></script>
{{/loadJs}}
{{#unless devEnv}}
{{> analysis}}
{{/unless}}
</body>
</html>