MCPcopy Create free account
hub / github.com/Lobos/react-ui / computedStyle

Function computedStyle

src/utils/dom.js:80–88  ·  view source on GitHub ↗
(el, attr)

Source from the content-addressed store, hash-verified

78}
79
80export function computedStyle (el, attr) {
81 var lineHeight;
82 if (el.currentStyle) {
83 lineHeight = el.currentStyle[attr]
84 } else if (window.getComputedStyle) {
85 lineHeight = window.getComputedStyle(el , null)[attr];
86 }
87 return lineHeight;
88}
89
90export function getLineHeight (origin) {
91 let el = origin.cloneNode(true);

Callers 1

componentDidMountMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…