push
github
236 of 1746 branches covered (13.52%)
5 of 11 new or added lines in 1 file covered. (45.45%)
1834 existing lines in 27 files now uncovered.370 of 2210 relevant lines covered (16.74%)
0.59 hits per line
1 |
export default function render(fn, useShadow) { |
|
UNCOV
2
|
return {
|
× |
3 |
get: useShadow
|
|
4 |
? (host) => { |
|
UNCOV
5
|
const updateDOM = fn(host); |
× |
6 |
const target = |
|
UNCOV
7
|
host.shadowRoot || |
|
8 |
host.attachShadow({ |
|
9 |
mode: "open", |
|
10 |
delegatesFocus: fn.delegatesFocus || false, |
|
11 |
}); |
|
UNCOV
12
|
return () => {
|
× |
UNCOV
13
|
updateDOM(host, target); |
× |
UNCOV
14
|
return target;
|
× |
15 |
}; |
|
16 |
} |
|
17 |
: (host) => { |
|
UNCOV
18
|
const updateDOM = fn(host); |
× |
UNCOV
19
|
return () => {
|
× |
UNCOV
20
|
updateDOM(host, host); |
× |
UNCOV
21
|
return host;
|
× |
22 |
}; |
|
23 |
}, |
|
24 |
observe(host, flush) { |
|
UNCOV
25
|
flush(); |
× |
26 |
}, |
|
27 |
}; |
|
28 |
} |