• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

hybridsjs / hybrids / 19760852732

28 Nov 2025 10:18AM UTC coverage: 42.528% (-57.4%) from 99.915%
19760852732

Pull #296

github

web-flow
Merge 191660095 into 92ed729fc
Pull Request #296: fix(store): improve `store.record()` support & error messages while defining the model

819 of 1842 branches covered (44.46%)

9 of 9 new or added lines in 1 file covered. (100.0%)

1345 existing lines in 27 files now uncovered.

996 of 2342 relevant lines covered (42.53%)

76.9 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/render.js
1
export default function render(desc) {
UNCOV
2
  if (desc.reflect) {
×
UNCOV
3
    throw TypeError(`'reflect' option is not supported for 'render' property`);
×
4
  }
5

UNCOV
6
  const { value: fn, observe } = desc;
×
7

UNCOV
8
  if (typeof fn !== "function") {
×
UNCOV
9
    throw TypeError(
×
10
      `Value for 'render' property must be a function: ${typeof fn}`,
11
    );
12
  }
13

UNCOV
14
  const result = {
×
15
    connect: desc.connect,
16
    observe: observe
×
17
      ? (host, flush, lastFlush) => {
UNCOV
18
          observe(host, flush(), lastFlush);
×
19
        }
20
      : (host, flush) => {
UNCOV
21
          flush();
×
22
        },
23
  };
24

UNCOV
25
  const shadow = desc.shadow
×
26
    ? {
27
        mode: desc.shadow.mode || "open",
×
28
        delegatesFocus: desc.shadow.delegatesFocus || false,
×
29
      }
30
    : desc.shadow;
31

UNCOV
32
  if (shadow) {
×
UNCOV
33
    result.value = (host) => {
×
UNCOV
34
      const target = host.shadowRoot || host.attachShadow(shadow);
×
UNCOV
35
      const update = fn(host);
×
36

UNCOV
37
      return () => {
×
UNCOV
38
        update(host, target);
×
UNCOV
39
        return target;
×
40
      };
41
    };
UNCOV
42
  } else if (shadow === false) {
×
UNCOV
43
    result.value = (host) => {
×
UNCOV
44
      const update = fn(host);
×
UNCOV
45
      return () => {
×
UNCOV
46
        update(host, host);
×
UNCOV
47
        return host;
×
48
      };
49
    };
50
  } else {
UNCOV
51
    result.value = (host) => {
×
UNCOV
52
      const update = fn(host);
×
UNCOV
53
      return () => update(host);
×
54
    };
55
  }
56

UNCOV
57
  return result;
×
58
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc