ripple 0.4.2 → 0.4.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (94) hide show
  1. package/CHANGELOG.md +107 -0
  2. package/package.json +9 -3
  3. package/src/jsx-runtime.d.ts +2 -1
  4. package/src/runtime/array.js +15 -9
  5. package/src/runtime/index-client.js +25 -7
  6. package/src/runtime/index-server.js +1 -0
  7. package/src/runtime/internal/client/attributes.js +313 -0
  8. package/src/runtime/internal/client/blocks.js +4 -14
  9. package/src/runtime/internal/client/component.js +2 -5
  10. package/src/runtime/internal/client/composite.js +14 -6
  11. package/src/runtime/internal/client/constants.js +6 -6
  12. package/src/runtime/internal/client/context.js +3 -2
  13. package/src/runtime/internal/client/css.js +11 -26
  14. package/src/runtime/internal/client/errors.js +188 -0
  15. package/src/runtime/internal/client/events.js +79 -34
  16. package/src/runtime/internal/client/expression.js +21 -116
  17. package/src/runtime/internal/client/for.js +108 -232
  18. package/src/runtime/internal/client/head.js +4 -3
  19. package/src/runtime/internal/client/html.js +5 -3
  20. package/src/runtime/internal/client/hydrate.js +484 -0
  21. package/src/runtime/internal/client/hydration-enabled.js +7 -0
  22. package/src/runtime/internal/client/hydration.js +16 -81
  23. package/src/runtime/internal/client/if.js +13 -9
  24. package/src/runtime/internal/client/index.js +14 -6
  25. package/src/runtime/internal/client/operations.js +11 -7
  26. package/src/runtime/internal/client/portal.js +3 -2
  27. package/src/runtime/internal/client/render.js +42 -325
  28. package/src/runtime/internal/client/root-boundary-enabled.js +7 -0
  29. package/src/runtime/internal/client/runtime.js +87 -363
  30. package/src/runtime/internal/client/template-ns.js +47 -0
  31. package/src/runtime/internal/client/template.js +63 -140
  32. package/src/runtime/internal/client/track-async.js +356 -0
  33. package/src/runtime/internal/client/try.js +133 -319
  34. package/src/runtime/internal/client/types.d.ts +48 -24
  35. package/src/runtime/internal/server/index.js +31 -29
  36. package/src/runtime/internal/server/prerender.js +27 -0
  37. package/src/server/index.js +1 -0
  38. package/src/utils/class-name.js +28 -0
  39. package/tests/client/basic/basic.errors.test.tsrx +3 -3
  40. package/tests/client/compiler/__snapshots__/compiler.typescript.test.tsrx.snap +0 -2
  41. package/tests/client/compiler/compiler.basic.test.tsrx +2 -2
  42. package/tests/client/compiler/compiler.tracked-access.test.tsrx +3 -3
  43. package/tests/client/composite/composite.props.test.tsrx +10 -10
  44. package/tests/client/derived-release.test.tsrx +3 -3
  45. package/tests/client/for-item.test.tsrx +39 -0
  46. package/tests/client/for-selector.test.tsrx +95 -0
  47. package/tests/hydration/compiled/client/basic.js +87 -87
  48. package/tests/hydration/compiled/client/composite.js +5 -5
  49. package/tests/hydration/compiled/client/events.js +40 -48
  50. package/tests/hydration/compiled/client/for.js +162 -181
  51. package/tests/hydration/compiled/client/fragment-cursor.js +521 -289
  52. package/tests/hydration/compiled/client/head.js +22 -22
  53. package/tests/hydration/compiled/client/hmr.js +4 -4
  54. package/tests/hydration/compiled/client/html-in-template.js +5 -5
  55. package/tests/hydration/compiled/client/html.js +152 -162
  56. package/tests/hydration/compiled/client/if-children.js +58 -53
  57. package/tests/hydration/compiled/client/if-fragment-controlflow.js +39 -39
  58. package/tests/hydration/compiled/client/if.js +26 -26
  59. package/tests/hydration/compiled/client/mixed-control-flow.js +56 -68
  60. package/tests/hydration/compiled/client/nested-control-flow.js +139 -271
  61. package/tests/hydration/compiled/client/portal.js +10 -10
  62. package/tests/hydration/compiled/client/reactivity.js +29 -29
  63. package/tests/hydration/compiled/client/return.js +2 -2
  64. package/tests/hydration/compiled/client/streaming.js +33 -35
  65. package/tests/hydration/compiled/client/switch.js +25 -25
  66. package/tests/hydration/compiled/client/track-async-serialization.js +41 -41
  67. package/tests/hydration/compiled/client/try.js +15 -15
  68. package/tests/hydration/compiled/client/typed-text.js +7 -7
  69. package/tests/hydration/compiled/server/basic.js +6 -6
  70. package/tests/hydration/compiled/server/events.js +8 -8
  71. package/tests/hydration/compiled/server/for.js +22 -22
  72. package/tests/hydration/compiled/server/fragment-cursor.js +188 -52
  73. package/tests/hydration/compiled/server/head.js +6 -6
  74. package/tests/hydration/compiled/server/hmr.js +1 -1
  75. package/tests/hydration/compiled/server/html.js +1 -1
  76. package/tests/hydration/compiled/server/if-children.js +9 -9
  77. package/tests/hydration/compiled/server/if.js +5 -5
  78. package/tests/hydration/compiled/server/mixed-control-flow.js +4 -4
  79. package/tests/hydration/compiled/server/portal.js +1 -1
  80. package/tests/hydration/compiled/server/reactivity.js +9 -9
  81. package/tests/hydration/compiled/server/streaming.js +9 -9
  82. package/tests/hydration/compiled/server/switch.js +4 -4
  83. package/tests/hydration/compiled/server/track-async-serialization.js +16 -16
  84. package/tests/hydration/compiled/server/try.js +4 -4
  85. package/tests/hydration/compiled/server/typed-text.js +1 -1
  86. package/tests/hydration/components/fragment-cursor.tsrx +60 -0
  87. package/tests/hydration/components/track-async-serialization.tsrx +2 -2
  88. package/tests/hydration/fragment-cursor.test.js +34 -1
  89. package/tests/hydration/track-async-serialization.test.js +1 -1
  90. package/tests/server/basic.components.test.tsrx +3 -3
  91. package/tests/server/track-async-serialization.test.tsrx +6 -6
  92. package/tests/utils/tracked-types.test.js +3 -3
  93. package/types/index.d.ts +8 -8
  94. package/types/server.d.ts +17 -0
@@ -1,7 +1,7 @@
1
1
  // @ts-nocheck
2
2
  import * as _$_ from 'ripple/internal/client';
3
3
 
4
- var root = _$_.template(`<div class="shown">Visible</div>`, 0);
4
+ var root = _$_.template(`<div class=shown>Visible`);
5
5
 
6
6
  function consequent(__anchor, show) {
7
7
  var div = root();
@@ -21,7 +21,7 @@ function IfTruthy_render(__anchor, __block) {
21
21
 
22
22
  IfTruthy[_$_.$r] = IfTruthy_render;
23
23
 
24
- var root_1 = _$_.template(`<div class="shown">Visible</div>`, 0);
24
+ var root_1 = _$_.template(`<div class=shown>Visible`);
25
25
 
26
26
  function consequent_1(__anchor, show) {
27
27
  var div_1 = root_1();
@@ -41,8 +41,8 @@ function IfFalsy_render(__anchor, __block) {
41
41
 
42
42
  IfFalsy[_$_.$r] = IfFalsy_render;
43
43
 
44
- var root_2 = _$_.template(`<div class="logged-in">Welcome back!</div>`, 0);
45
- var root_3 = _$_.template(`<div class="logged-out">Please log in</div>`, 0);
44
+ var root_2 = _$_.template(`<div class=logged-in>Welcome back!`);
45
+ var root_3 = _$_.template(`<div class=logged-out>Please log in`);
46
46
 
47
47
  function consequent_2(__anchor, isLoggedIn) {
48
48
  var div_2 = root_2();
@@ -68,7 +68,7 @@ function IfElse_render(__anchor, __block) {
68
68
 
69
69
  IfElse[_$_.$r] = IfElse_render;
70
70
 
71
- var root_6 = _$_.template(`<div class="content">Content visible</div>`, 0);
71
+ var root_6 = _$_.template(`<div class=content>Content visible`);
72
72
 
73
73
  function consequent_3(__anchor, show) {
74
74
  var div_4 = root_6();
@@ -80,11 +80,11 @@ function if_4(show) {
80
80
  if (show.value) return consequent_3;
81
81
  }
82
82
 
83
- var root_5 = _$_.template(`<button class="toggle">Toggle</button><!>`, 1, 2);
83
+ var root_5 = _$_.template(`<button class=toggle>Toggle</button><!>`, 1, 2);
84
84
  var root_4 = _$_.template(`<!>`, 1, 1);
85
85
 
86
86
  function ReactiveIf_render(__anchor, __block) {
87
- const show = _$_.track(true, __block, '19a16ff0');
87
+ const show = _$_.track(true, __block, '740m40');
88
88
  var fragment = root_4();
89
89
  var node_1 = _$_.first_child_frag(fragment);
90
90
 
@@ -107,8 +107,8 @@ function ReactiveIf_render(__anchor, __block) {
107
107
 
108
108
  ReactiveIf[_$_.$r] = ReactiveIf_render;
109
109
 
110
- var root_9 = _$_.template(`<div class="on">ON</div>`, 0);
111
- var root_10 = _$_.template(`<div class="off">OFF</div>`, 0);
110
+ var root_9 = _$_.template(`<div class=on>ON`);
111
+ var root_10 = _$_.template(`<div class=off>OFF`);
112
112
 
113
113
  function consequent_4(__anchor, isOn) {
114
114
  var div_5 = root_9();
@@ -126,11 +126,11 @@ function if_5(isOn) {
126
126
  if (isOn.value) return consequent_4; else return alternate_1;
127
127
  }
128
128
 
129
- var root_8 = _$_.template(`<button class="toggle">Toggle</button><!>`, 1, 2);
129
+ var root_8 = _$_.template(`<button class=toggle>Toggle</button><!>`, 1, 2);
130
130
  var root_7 = _$_.template(`<!>`, 1, 1);
131
131
 
132
132
  function ReactiveIfElse_render(__anchor, __block) {
133
- const isOn = _$_.track(false, __block, '41177f39');
133
+ const isOn = _$_.track(false, __block, 'i26m2h');
134
134
  var fragment_2 = root_7();
135
135
  var node_3 = _$_.first_child_frag(fragment_2);
136
136
 
@@ -153,7 +153,7 @@ function ReactiveIfElse_render(__anchor, __block) {
153
153
 
154
154
  ReactiveIfElse[_$_.$r] = ReactiveIfElse_render;
155
155
 
156
- var root_14 = _$_.template(`<span class="inner-content">Inner</span>`, 0);
156
+ var root_14 = _$_.template(`<span class=inner-content>Inner`);
157
157
 
158
158
  function consequent_5(__anchor, inner) {
159
159
  var span = root_14();
@@ -165,14 +165,14 @@ function if_6(inner) {
165
165
  if (inner.value) return consequent_5;
166
166
  }
167
167
 
168
- var root_13 = _$_.template(`<div class="outer-content">Outer</div>`, 0);
168
+ var root_13 = _$_.template(`<div class=outer-content>Outer`);
169
169
 
170
- function consequent_6(__anchor, { outer, inner }) {
170
+ function consequent_6(__anchor, { a: outer, b: inner }) {
171
171
  var div_7 = root_13();
172
172
 
173
173
  {
174
174
  var expression = _$_.hydrating ? _$_.hydrate_child() : div_7.firstChild;
175
- var node_5 = _$_.hydrating ? _$_.hydrate_sibling() : _$_.append_into(div_7);
175
+ var node_5 = _$_.hydrating ? _$_.hydrate_sibling() : _$_.append_into(div_7, true);
176
176
 
177
177
  _$_.if(node_5, if_6, false, inner);
178
178
  _$_.hydrating && _$_.pop(div_7);
@@ -181,16 +181,16 @@ function consequent_6(__anchor, { outer, inner }) {
181
181
  _$_.append(__anchor, div_7);
182
182
  }
183
183
 
184
- function if_7({ outer, inner }) {
184
+ function if_7({ a: outer, b: inner }) {
185
185
  if (outer.value) return consequent_6;
186
186
  }
187
187
 
188
- var root_12 = _$_.template(`<button class="outer-toggle">Outer</button><button class="inner-toggle">Inner</button><!>`, 1, 3);
188
+ var root_12 = _$_.template(`<button class=outer-toggle>Outer</button><button class=inner-toggle>Inner</button><!>`, 1, 3);
189
189
  var root_11 = _$_.template(`<!>`, 1, 1);
190
190
 
191
191
  function NestedIf_render(__anchor, __block) {
192
- const outer = _$_.track(true, __block, '7894e1df');
193
- const inner = _$_.track(true, __block, 'f21b8c26');
192
+ const outer = _$_.track(true, __block, 'xggelb');
193
+ const inner = _$_.track(true, __block, '1v6cfmu');
194
194
  var fragment_4 = root_11();
195
195
  var node_6 = _$_.first_child_frag(fragment_4);
196
196
 
@@ -210,7 +210,7 @@ function NestedIf_render(__anchor, __block) {
210
210
 
211
211
  var node_4 = _$_.hydrating ? _$_.hydrate_sibling() : button_3.nextSibling;
212
212
 
213
- _$_.if(node_4, if_7, false, { outer, inner });
213
+ _$_.if(node_4, if_7, false, { a: outer, b: inner });
214
214
  _$_.append(__anchor, fragment_5);
215
215
  }));
216
216
 
@@ -219,9 +219,9 @@ function NestedIf_render(__anchor, __block) {
219
219
 
220
220
  NestedIf[_$_.$r] = NestedIf_render;
221
221
 
222
- var root_16 = _$_.template(`<div class="state">Loading...</div>`, 0);
223
- var root_17 = _$_.template(`<div class="state">Success!</div>`, 0);
224
- var root_18 = _$_.template(`<div class="state">Error occurred</div>`, 0);
222
+ var root_16 = _$_.template(`<div class=state>Loading...`);
223
+ var root_17 = _$_.template(`<div class=state>Success!`);
224
+ var root_18 = _$_.template(`<div class=state>Error occurred`);
225
225
 
226
226
  function consequent_7(__anchor, status) {
227
227
  var div_9 = root_16();
@@ -245,10 +245,10 @@ function if_8(status) {
245
245
  if (status.value === 'loading') return consequent_7; else if (status.value === 'success') return consequent_8; else return alternate_2;
246
246
  }
247
247
 
248
- var root_15 = _$_.template(`<div><button class="success">Success</button><button class="error">Error</button><button class="loading">Loading</button></div>`, 0);
248
+ var root_15 = _$_.template(`<div><button class=success>Success</button><button class=error>Error</button><button class=loading>Loading`);
249
249
 
250
250
  function IfElseIfChain_render(__anchor, __block) {
251
- const status = _$_.track('loading', __block, '4c69c94a');
251
+ const status = _$_.track('loading', __block, 'l79qh6');
252
252
  var div_8 = root_15();
253
253
 
254
254
  {
@@ -270,7 +270,7 @@ function IfElseIfChain_render(__anchor, __block) {
270
270
  status.value = 'loading';
271
271
  };
272
272
 
273
- var node_7 = _$_.hydrating ? _$_.hydrate_sibling() : _$_.append_into(div_8);
273
+ var node_7 = _$_.hydrating ? _$_.hydrate_sibling() : _$_.append_into(div_8, true);
274
274
 
275
275
  _$_.if(node_7, if_8, false, status);
276
276
  _$_.hydrating && _$_.pop(div_8);
@@ -1,59 +1,59 @@
1
1
  // @ts-nocheck
2
2
  import * as _$_ from 'ripple/internal/client';
3
3
 
4
- var root_1 = _$_.template(`<div></div>`, 0);
4
+ var root_1 = _$_.template(`<div>`);
5
5
 
6
6
  function render(__prev) {
7
- var __pattern = _$_.get(__prev._pattern);
7
+ var __pattern = _$_.get(__prev._a);
8
8
  var __a = `A-${__pattern.id}`;
9
9
 
10
10
  if (__prev.a !== __a) {
11
- _$_.set_text_content(__prev._div, __a, __prev.a);
11
+ _$_.set_text_content(__prev._b, __a, __prev.a);
12
12
  __prev.a = __a;
13
13
  }
14
14
 
15
15
  var __b = `row row-${__pattern.id} kind-a`;
16
16
 
17
17
  if (__prev.b !== __b) {
18
- _$_.set_class(__prev._div, __prev.b = __b, void 0, true);
18
+ _$_.set_class(__prev._b, __prev.b = __b);
19
19
  }
20
20
  }
21
21
 
22
- var root_2 = _$_.template(`<div>pending a</div>`, 0);
22
+ var root_2 = _$_.template(`<div>pending a`);
23
23
 
24
24
  function render_1(__prev) {
25
- var __a = `pending pending-${_$_.get(__prev._pattern).id}`;
25
+ var __a = `pending pending-${_$_.get(__prev._a).id}`;
26
26
 
27
27
  if (__prev.a !== __a) {
28
- _$_.set_class(__prev._div_1, __prev.a = __a, void 0, true);
28
+ _$_.set_class(__prev._b, __prev.a = __a);
29
29
  }
30
30
  }
31
31
 
32
- var root_3 = _$_.template(`<div></div>`, 0);
32
+ var root_3 = _$_.template(`<div>`);
33
33
 
34
34
  function render_2(__prev) {
35
- var __pattern_1 = _$_.get(__prev._pattern);
35
+ var __pattern_1 = _$_.get(__prev._a);
36
36
  var __a = `B-${__pattern_1.id}`;
37
37
 
38
38
  if (__prev.a !== __a) {
39
- _$_.set_text_content(__prev._div_2, __a, __prev.a);
39
+ _$_.set_text_content(__prev._b, __a, __prev.a);
40
40
  __prev.a = __a;
41
41
  }
42
42
 
43
43
  var __b = `row row-${__pattern_1.id} kind-b`;
44
44
 
45
45
  if (__prev.b !== __b) {
46
- _$_.set_class(__prev._div_2, __prev.b = __b, void 0, true);
46
+ _$_.set_class(__prev._b, __prev.b = __b);
47
47
  }
48
48
  }
49
49
 
50
- var root_4 = _$_.template(`<div>pending b</div>`, 0);
50
+ var root_4 = _$_.template(`<div>pending b`);
51
51
 
52
52
  function render_3(__prev) {
53
- var __a = `pending pending-${_$_.get(__prev._pattern).id}`;
53
+ var __a = `pending pending-${_$_.get(__prev._a).id}`;
54
54
 
55
55
  if (__prev.a !== __a) {
56
- _$_.set_class(__prev._div_3, __prev.a = __a, void 0, true);
56
+ _$_.set_class(__prev._b, __prev.a = __a);
57
57
  }
58
58
  }
59
59
 
@@ -63,14 +63,14 @@ function switch_case_0(__anchor, pattern) {
63
63
  (__anchor) => {
64
64
  var div = root_1();
65
65
 
66
- _$_.render(render, { a: '', b: _$_.UNINITIALIZED, _pattern: pattern, _div: div });
66
+ _$_.render(render, { a: '', b: _$_.UNINITIALIZED, _a: pattern, _b: div });
67
67
  _$_.append(__anchor, div);
68
68
  },
69
69
  null,
70
70
  (__anchor) => {
71
71
  var div_1 = root_2();
72
72
 
73
- _$_.render(render_1, { a: _$_.UNINITIALIZED, _pattern: pattern, _div_1: div_1 });
73
+ _$_.render(render_1, { a: _$_.UNINITIALIZED, _a: pattern, _b: div_1 });
74
74
  _$_.append(__anchor, div_1);
75
75
  },
76
76
  true
@@ -83,20 +83,14 @@ function switch_case_default(__anchor, pattern) {
83
83
  (__anchor) => {
84
84
  var div_2 = root_3();
85
85
 
86
- _$_.render(render_2, {
87
- a: '',
88
- b: _$_.UNINITIALIZED,
89
- _pattern: pattern,
90
- _div_2: div_2
91
- });
92
-
86
+ _$_.render(render_2, { a: '', b: _$_.UNINITIALIZED, _a: pattern, _b: div_2 });
93
87
  _$_.append(__anchor, div_2);
94
88
  },
95
89
  null,
96
90
  (__anchor) => {
97
91
  var div_3 = root_4();
98
92
 
99
- _$_.render(render_3, { a: _$_.UNINITIALIZED, _pattern: pattern, _div_3: div_3 });
93
+ _$_.render(render_3, { a: _$_.UNINITIALIZED, _a: pattern, _b: div_3 });
100
94
  _$_.append(__anchor, div_3);
101
95
  },
102
96
  true
@@ -121,7 +115,7 @@ function if_1(pattern) {
121
115
  if (_$_.get(pattern).enabled) return consequent;
122
116
  }
123
117
 
124
- var root = _$_.template(`<section class="mixed-static"></section>`, 0);
118
+ var root = _$_.template(`<section class=mixed-static>`);
125
119
 
126
120
  function MixedControlFlowStatic_render(__anchor, __block) {
127
121
  const rows = [
@@ -151,52 +145,52 @@ function MixedControlFlowStatic_render(__anchor, __block) {
151
145
 
152
146
  MixedControlFlowStatic[_$_.$r] = MixedControlFlowStatic_render;
153
147
 
154
- var root_8 = _$_.template(`<p></p>`, 0);
148
+ var root_8 = _$_.template(`<p>`);
155
149
 
156
150
  function render_4(__prev) {
157
- var __pattern_1_1 = _$_.get(__prev._pattern_1);
151
+ var __pattern_1_1 = _$_.get(__prev._a);
158
152
  var __a = `A:${__pattern_1_1.label}`;
159
153
 
160
154
  if (__prev.a !== __a) {
161
- _$_.set_text_content(__prev._p, __a, __prev.a);
155
+ _$_.set_text_content(__prev._b, __a, __prev.a);
162
156
  __prev.a = __a;
163
157
  }
164
158
 
165
159
  var __b = `item item-${__pattern_1_1.id}`;
166
160
 
167
161
  if (__prev.b !== __b) {
168
- _$_.set_class(__prev._p, __prev.b = __b, void 0, true);
162
+ _$_.set_class(__prev._b, __prev.b = __b);
169
163
  }
170
164
  }
171
165
 
172
- var root_9 = _$_.template(`<p class="pending">pending a</p>`, 0);
173
- var root_10 = _$_.template(`<p></p>`, 0);
166
+ var root_9 = _$_.template(`<p class=pending>pending a`);
167
+ var root_10 = _$_.template(`<p>`);
174
168
 
175
169
  function render_5(__prev) {
176
- var __pattern_1_2 = _$_.get(__prev._pattern_1);
170
+ var __pattern_1_2 = _$_.get(__prev._a);
177
171
  var __a = `B:${__pattern_1_2.label}`;
178
172
 
179
173
  if (__prev.a !== __a) {
180
- _$_.set_text_content(__prev._p_2, __a, __prev.a);
174
+ _$_.set_text_content(__prev._b, __a, __prev.a);
181
175
  __prev.a = __a;
182
176
  }
183
177
 
184
178
  var __b = `item item-${__pattern_1_2.id}`;
185
179
 
186
180
  if (__prev.b !== __b) {
187
- _$_.set_class(__prev._p_2, __prev.b = __b, void 0, true);
181
+ _$_.set_class(__prev._b, __prev.b = __b);
188
182
  }
189
183
  }
190
184
 
191
- var root_11 = _$_.template(`<p class="pending">pending b</p>`, 0);
185
+ var root_11 = _$_.template(`<p class=pending>pending b`);
192
186
 
193
- function switch_case_0_1(__anchor, { mode, pattern_1 }) {
187
+ function switch_case_0_1(__anchor, { a: mode, b: pattern_1 }) {
194
188
  _$_.try(
195
189
  __anchor,
196
190
  (__anchor) => {
197
191
  var p = root_8();
198
192
 
199
- _$_.render(render_4, { a: '', b: _$_.UNINITIALIZED, _pattern_1: pattern_1, _p: p });
193
+ _$_.render(render_4, { a: '', b: _$_.UNINITIALIZED, _a: pattern_1, _b: p });
200
194
  _$_.append(__anchor, p);
201
195
  },
202
196
  null,
@@ -209,19 +203,13 @@ function switch_case_0_1(__anchor, { mode, pattern_1 }) {
209
203
  );
210
204
  }
211
205
 
212
- function switch_case_default_1(__anchor, { mode, pattern_1 }) {
206
+ function switch_case_default_1(__anchor, { a: mode, b: pattern_1 }) {
213
207
  _$_.try(
214
208
  __anchor,
215
209
  (__anchor) => {
216
210
  var p_2 = root_10();
217
211
 
218
- _$_.render(render_5, {
219
- a: '',
220
- b: _$_.UNINITIALIZED,
221
- _pattern_1: pattern_1,
222
- _p_2: p_2
223
- });
224
-
212
+ _$_.render(render_5, { a: '', b: _$_.UNINITIALIZED, _a: pattern_1, _b: p_2 });
225
213
  _$_.append(__anchor, p_2);
226
214
  },
227
215
  null,
@@ -234,7 +222,7 @@ function switch_case_default_1(__anchor, { mode, pattern_1 }) {
234
222
  );
235
223
  }
236
224
 
237
- function switch_2({ mode, pattern_1 }) {
225
+ function switch_2({ a: mode, b: pattern_1 }) {
238
226
  switch (mode.value) {
239
227
  case 'a':
240
228
  return switch_case_0_1;
@@ -244,9 +232,9 @@ function switch_2({ mode, pattern_1 }) {
244
232
  }
245
233
  }
246
234
 
247
- var root_7 = _$_.template(`<div class="mixed-reactive-list"></div>`, 0);
235
+ var root_7 = _$_.template(`<div class=mixed-reactive-list>`);
248
236
 
249
- function consequent_1(__anchor, { show, items, mode }) {
237
+ function consequent_1(__anchor, { a: show, b: items, c: mode }) {
250
238
  var div_4 = root_7();
251
239
 
252
240
  {
@@ -254,7 +242,7 @@ function consequent_1(__anchor, { show, items, mode }) {
254
242
  div_4,
255
243
  () => items.value,
256
244
  (__anchor, pattern_1) => {
257
- _$_.switch(__anchor, switch_2, true, { mode, pattern_1 });
245
+ _$_.switch(__anchor, switch_2, true, { a: mode, b: pattern_1 });
258
246
  },
259
247
  4,
260
248
  (pattern_1) => pattern_1.id
@@ -266,17 +254,17 @@ function consequent_1(__anchor, { show, items, mode }) {
266
254
  _$_.append(__anchor, div_4);
267
255
  }
268
256
 
269
- function if_2({ show, items, mode }) {
257
+ function if_2({ a: show, b: items, c: mode }) {
270
258
  if (show.value) return consequent_1;
271
259
  }
272
260
 
273
- var root_6 = _$_.template(`<button class="toggle-show">Toggle Show</button><button class="toggle-mode">Toggle Mode</button><button class="add-item">Add Item</button><!>`, 1, 4);
261
+ var root_6 = _$_.template(`<button class=toggle-show>Toggle Show</button><button class=toggle-mode>Toggle Mode</button><button class=add-item>Add Item</button><!>`, 1, 4);
274
262
  var root_5 = _$_.template(`<!>`, 1, 1);
275
263
 
276
264
  function MixedControlFlowReactive_render(__anchor, __block) {
277
- const show = _$_.track(true, __block, '5ae53d26');
278
- const mode = _$_.track('a', __block, '5b53eda2');
279
- const items = _$_.track([{ id: 1, label: 'One' }, { id: 2, label: 'Two' }], __block, '7890dad6');
265
+ const show = _$_.track(true, __block, 'p7xgkm');
266
+ const mode = _$_.track('a', __block, 'pc8xwi');
267
+ const items = _$_.track([{ id: 1, label: 'One' }, { id: 2, label: 'Two' }], __block, 'xgaqxi');
280
268
  var fragment = root_5();
281
269
  var node_1 = _$_.first_child_frag(fragment);
282
270
 
@@ -302,7 +290,7 @@ function MixedControlFlowReactive_render(__anchor, __block) {
302
290
 
303
291
  var node = _$_.hydrating ? _$_.hydrate_sibling() : button_2.nextSibling;
304
292
 
305
- _$_.if(node, if_2, false, { show, items, mode });
293
+ _$_.if(node, if_2, false, { a: show, b: items, c: mode });
306
294
  _$_.append(__anchor, fragment_1);
307
295
  }));
308
296
 
@@ -311,10 +299,10 @@ function MixedControlFlowReactive_render(__anchor, __block) {
311
299
 
312
300
  MixedControlFlowReactive[_$_.$r] = MixedControlFlowReactive_render;
313
301
 
314
- var root_14 = _$_.template(`<div></div>`, 0);
315
- var root_15 = _$_.template(`<div class="unexpected">unexpected</div>`, 0);
302
+ var root_14 = _$_.template(`<div>`);
303
+ var root_15 = _$_.template(`<div class=unexpected>unexpected`);
316
304
 
317
- function switch_case_0_2(__anchor, { state, row }) {
305
+ function switch_case_0_2(__anchor, { a: state, b: row }) {
318
306
  _$_.try(
319
307
  __anchor,
320
308
  (__anchor) => {
@@ -324,7 +312,7 @@ function switch_case_0_2(__anchor, { state, row }) {
324
312
  (__anchor) => {
325
313
  var div_6 = root_14();
326
314
 
327
- _$_.set_class(div_6, `pending-row pending-row-${row}`, void 0, true);
315
+ _$_.set_class(div_6, `pending-row pending-row-${row}`);
328
316
 
329
317
  {
330
318
  div_6.textContent = `pending ${row}`;
@@ -336,13 +324,13 @@ function switch_case_0_2(__anchor, { state, row }) {
336
324
  );
337
325
  }
338
326
 
339
- function switch_case_default_2(__anchor, { state, row }) {
327
+ function switch_case_default_2(__anchor, { a: state, b: row }) {
340
328
  var div_7 = root_15();
341
329
 
342
330
  _$_.append(__anchor, div_7);
343
331
  }
344
332
 
345
- function switch_3({ state, row }) {
333
+ function switch_3({ a: state, b: row }) {
346
334
  switch (state) {
347
335
  case 'slow':
348
336
  return switch_case_0_2;
@@ -352,15 +340,15 @@ function switch_3({ state, row }) {
352
340
  }
353
341
  }
354
342
 
355
- function consequent_2(__anchor, { row, state }) {
356
- _$_.switch(__anchor, switch_3, true, { state, row });
343
+ function consequent_2(__anchor, { a: row, b: state }) {
344
+ _$_.switch(__anchor, switch_3, true, { a: state, b: row });
357
345
  }
358
346
 
359
- function if_3({ row, state }) {
347
+ function if_3({ a: row, b: state }) {
360
348
  if (row === 1) return consequent_2;
361
349
  }
362
350
 
363
- var root_13 = _$_.template(`<div class="before">before</div><!>`, 1, 2);
351
+ var root_13 = _$_.template(`<div class=before>before</div><!>`, 1, 2);
364
352
  var root_12 = _$_.template(`<!>`, 1, 1);
365
353
 
366
354
  function MixedControlFlowAsyncPending_render(__anchor, __block) {
@@ -378,7 +366,7 @@ function MixedControlFlowAsyncPending_render(__anchor, __block) {
378
366
  node_2,
379
367
  () => rows,
380
368
  (__anchor, row) => {
381
- _$_.if(__anchor, if_3, true, { row, state });
369
+ _$_.if(__anchor, if_3, true, { a: row, b: state });
382
370
  },
383
371
  0
384
372
  );
@@ -391,10 +379,10 @@ function MixedControlFlowAsyncPending_render(__anchor, __block) {
391
379
 
392
380
  MixedControlFlowAsyncPending[_$_.$r] = MixedControlFlowAsyncPending_render;
393
381
 
394
- var root_16 = _$_.template(`<div class="resolved-row"> </div>`, 0);
382
+ var root_16 = _$_.template(`<div class=resolved-row> `);
395
383
 
396
384
  function AsyncRow_render(__anchor, __block, { label }) {
397
- const value = _$_.track_async(() => _$_.with_scope(__block, () => Promise.resolve(label)), __block, '10cc79a0');
385
+ const value = _$_.track_async(() => _$_.with_scope(__block, () => Promise.resolve(label)), __block, '4nsq00');
398
386
  var div_8 = root_16();
399
387
 
400
388
  {