CARVIEW |
Select Language
HTTP/2 301
location: https://raw.githubusercontent.com/twolfson/computedStyle/master/dist/computedStyle.amd.js
accept-ranges: bytes
date: Tue, 22 Jul 2025 23:32:55 GMT
via: 1.1 varnish
age: 0
x-served-by: cache-bom-vanm7210021-BOM
x-cache: MISS
x-cache-hits: 0
x-timer: S1753227175.696127,VS0,VE927
vary: Accept-Encoding
x-fastly-request-id: 206fc346d3a09d358ad67963f0b74c7aea61b6c4
content-length: 0
HTTP/2 200
cache-control: max-age=300
content-security-policy: default-src 'none'; style-src 'unsafe-inline'; sandbox
content-type: text/plain; charset=utf-8
etag: W/"4d21e5ba981a018892156ab794725e25d56139651616a88271cd5352a3366e76"
strict-transport-security: max-age=31536000
x-content-type-options: nosniff
x-frame-options: deny
x-xss-protection: 1; mode=block
x-github-request-id: 8714:3B900B:2ECDB:A71F6:68801FA2
content-encoding: gzip
accept-ranges: bytes
date: Tue, 22 Jul 2025 23:32:55 GMT
via: 1.1 varnish
x-served-by: cache-bom-vanm7210061-BOM
x-cache: MISS
x-cache-hits: 0
x-timer: S1753227176.674693,VS0,VE269
vary: Authorization,Accept-Encoding
access-control-allow-origin: *
cross-origin-resource-policy: cross-origin
x-fastly-request-id: 419bad96d2d4a587cf3e7e1847d56d42f0152222
expires: Tue, 22 Jul 2025 23:37:55 GMT
source-age: 0
content-length: 473
define(function () {
// DEV: We don't use var but favor parameters since these play nicer with minification
function computedStyle(el, prop, getComputedStyle, style) {
getComputedStyle = window.getComputedStyle;
style =
// If we have getComputedStyle
getComputedStyle ?
// Query it
// TODO: From CSS-Query notes, we might need (node, null) for FF
getComputedStyle(el) :
// Otherwise, we are in IE and use currentStyle
el.currentStyle;
if (style) {
return style
[
// Switch to camelCase for CSSOM
// DEV: Grabbed from jQuery
// https://github.com/jquery/jquery/blob/1.9-stable/src/css.js#L191-L194
// https://github.com/jquery/jquery/blob/1.9-stable/src/core.js#L593-L597
prop.replace(/-(\w)/gi, function (word, letter) {
return letter.toUpperCase();
})
];
}
}
return computedStyle;
});