-
Notifications
You must be signed in to change notification settings - Fork 4
/
index.tpl
49 lines (47 loc) · 1.55 KB
/
index.tpl
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
doctype html
html(lang="en")
head
meta(http-equiv="x-ua-compatible", content="ie=edge")
meta(charset="utf-8")
title EnyoBench
link(rel='shortcut icon', href='assets/favicon.ico')
meta(http-equiv='Content-Type', content='text/html; charset=utf8')
meta(name='apple-mobile-web-app-capable', content='yes')
meta(name='viewport', content='width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no')
link(rel='stylesheet', type='text/css', href='style/bootstrap.css')
link(rel='stylesheet', type='text/css', href='style/main.css')
script.
var now = (function () {
// we have to check whether or not the browser has supplied a valid
// method to use
var perf = window.performance || {};
// test against all known vendor-specific implementations,
// but use a fallback just in case
perf.now = perf.now || perf.mozNow || perf.msNow || perf.oNow || perf.webkitNow ||
function() { return Date.now(); };
return function () {
return perf.now();
};
}());
var enyoBench = {
timing: {}
};
enyoBench.timing.enyoLoadStart = now();
each stylesheet in stylesheets
if stylesheet.href
link(rel="stylesheet", href=stylesheet.href)
else
style!= stylesheet.contents
each script, i in scripts
if i == scripts.length - 1
if scripts.length != 1
script.
enyoBench.timing.enyoLoadEnd = now();
enyoBench.timing.appLoadStart = now();
if script.src
script(src=script.src)
else
script!= script.contents
script.
enyoBench.timing.appLoadEnd = now();
body.enyo-unselectable