-
Notifications
You must be signed in to change notification settings - Fork 0
/
PerformanceServerTiming.cljs
90 lines (61 loc) · 2.43 KB
/
PerformanceServerTiming.cljs
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
(ns web.performance.PerformanceServerTiming
"The PerformanceServerTiming interface surfaces server metrics
are sent with the response in the `Server-Timing` HTTP header."
(:refer-clojure :exclude [name]))
(defn to-json
"Method.
The toJSON() method of the `web.performance.PerformanceServerTiming`
returns a `web.dom.DOMString` that is the JSON representation
the `web.performance.PerformanceServerTiming` object.
`var json = PerformanceServerTiming.toJSON()`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PerformanceServerTiming/toJSON`"
[this ]
(-> this (.toJSON)))
(defn description
"Property.
The description read-only property returns a `web.dom.DOMString`
of the server-specified metric description, or an empty string.
`serverTiming.description;`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PerformanceServerTiming/description`"
[this]
(-> this (.-description)))
(defn set-description!
"Property.
The description read-only property returns a `web.dom.DOMString`
of the server-specified metric description, or an empty string.
`serverTiming.description;`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PerformanceServerTiming/description`"
[this val]
(aset this "description" val))
(defn duration
"Property.
The duration read-only property returns a double that contains
server-specified metric duration, or value 0.0.
`serverTiming.duration;`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PerformanceServerTiming/duration`"
[this]
(-> this (.-duration)))
(defn set-duration!
"Property.
The duration read-only property returns a double that contains
server-specified metric duration, or value 0.0.
`serverTiming.duration;`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PerformanceServerTiming/duration`"
[this val]
(aset this "duration" val))
(defn name
"Property.
The name read-only property returns a `web.dom.DOMString` value
the server-specified metric name.
`serverTiming.name;`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PerformanceServerTiming/name`"
[this]
(-> this (.-name)))
(defn set-name!
"Property.
The name read-only property returns a `web.dom.DOMString` value
the server-specified metric name.
`serverTiming.name;`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PerformanceServerTiming/name`"
[this val]
(aset this "name" val))