solid-js 1.8.21 → 1.8.23

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.
package/README.md CHANGED
@@ -30,7 +30,7 @@ Solid is a declarative JavaScript library for creating user interfaces. Instead
30
30
  - A growing community and ecosystem with active core team support
31
31
 
32
32
  <details>
33
-
33
+
34
34
  <summary>Quick Start</summary>
35
35
 
36
36
  You can get started with a simple app by running the following in your terminal:
@@ -81,7 +81,7 @@ For TypeScript to work, remember to set your `.tsconfig` to handle Solid's JSX:
81
81
 
82
82
  ### Performant
83
83
 
84
- Meticulously engineered for performance and with half a decade of research behind it, Solid's performance is almost indistinguishable from optimized vanilla JavaScript (See Solid on the [JS Framework Benchmark](https://rawgit.com/krausest/js-framework-benchmark/master/webdriver-ts-results/table.html)). Solid is [small](https://bundlephobia.com/package/solid-js@1.3.15) and completely tree-shakable, and [fast](https://levelup.gitconnected.com/how-we-wrote-the-fastest-javascript-ui-framework-again-db097ddd99b6) when rendering on the server, too. Whether you're writing a fully client-rendered SPA or a server-rendered app, your users see it faster than ever. ([Read more about Solid's performance](https://dev.to/ryansolid/thinking-granular-how-is-solidjs-so-performant-4g37) from the library's creator.)
84
+ Meticulously engineered for performance and with half a decade of research behind it, Solid's performance is almost indistinguishable from optimized vanilla JavaScript (See Solid on the [JS Framework Benchmark](https://krausest.github.io/js-framework-benchmark/current.html)). Solid is [small](https://bundlephobia.com/package/solid-js@1.3.15) and completely tree-shakable, and [fast](https://levelup.gitconnected.com/how-we-wrote-the-fastest-javascript-ui-framework-again-db097ddd99b6) when rendering on the server, too. Whether you're writing a fully client-rendered SPA or a server-rendered app, your users see it faster than ever. ([Read more about Solid's performance](https://dev.to/ryansolid/thinking-granular-how-is-solidjs-so-performant-4g37) from the library's creator.)
85
85
 
86
86
  ### Powerful
87
87
 
@@ -93,7 +93,7 @@ Do more with less: use simple, composable primitives without hidden rules and go
93
93
 
94
94
  ### Productive
95
95
 
96
- Solid is built on established tools like JSX and TypeScript and integrates with the Vite ecosystem. Solid's bare-metal, minimal abstractions give you direct access to the DOM, making it easy to use your favorite native JavaScript libraries like D3. And the Solid ecosystem is growing fast, with [custom primitives](https://github.com/solidjs-community/solid-primitives), [component libraries](https://hope-ui.com/), and build-time utilities that let you [write Solid code in new ways](https://github.com/LXSMNSYC/solid-labels).
96
+ Solid is built on established tools like JSX and TypeScript and integrates with the Vite ecosystem. Solid's bare-metal, minimal abstractions give you direct access to the DOM, making it easy to use your favorite native JavaScript libraries like D3. And the Solid ecosystem is growing fast, with [custom primitives](https://github.com/solidjs-community/solid-primitives), [component libraries](https://github.com/hope-ui/hope-ui), and build-time utilities that let you [write Solid code in new ways](https://github.com/LXSMNSYC/solid-labels).
97
97
 
98
98
  <details>
99
99
  <summary>Show Me!</summary>
package/dist/dev.cjs CHANGED
@@ -119,6 +119,7 @@ function workLoop(hasTimeRemaining, initialTime) {
119
119
  const sharedConfig = {
120
120
  context: undefined,
121
121
  registry: undefined,
122
+ effects: undefined,
122
123
  done: false,
123
124
  getContextId() {
124
125
  return getContextId(this.context.count);
@@ -145,6 +146,7 @@ function nextHydrateContext() {
145
146
 
146
147
  const equalFn = (a, b) => a === b;
147
148
  const $PROXY = Symbol("solid-proxy");
149
+ const SUPPORTS_PROXY = typeof Proxy === "function";
148
150
  const $TRACK = Symbol("solid-track");
149
151
  const $DEVCOMP = Symbol("solid-dev-component");
150
152
  const signalOptions = {
@@ -912,13 +914,14 @@ function runUserEffects(queue) {
912
914
  sharedConfig.effects || (sharedConfig.effects = []);
913
915
  sharedConfig.effects.push(...queue.slice(0, userLength));
914
916
  return;
915
- } else if (sharedConfig.effects) {
916
- queue = [...sharedConfig.effects, ...queue];
917
- userLength += sharedConfig.effects.length;
918
- delete sharedConfig.effects;
919
917
  }
920
918
  setHydrateContext();
921
919
  }
920
+ if (sharedConfig.effects && (sharedConfig.done || !sharedConfig.count)) {
921
+ queue = [...sharedConfig.effects, ...queue];
922
+ userLength += sharedConfig.effects.length;
923
+ delete sharedConfig.effects;
924
+ }
922
925
  for (i = 0; i < userLength; i++) runTop(queue[i]);
923
926
  }
924
927
  function lookUpstream(node, ignore) {
@@ -963,11 +966,11 @@ function cleanNode(node) {
963
966
  }
964
967
  }
965
968
  }
969
+ if (node.tOwned) {
970
+ for (i = node.tOwned.length - 1; i >= 0; i--) cleanNode(node.tOwned[i]);
971
+ delete node.tOwned;
972
+ }
966
973
  if (Transition && Transition.running && node.pure) {
967
- if (node.tOwned) {
968
- for (i = node.tOwned.length - 1; i >= 0; i--) cleanNode(node.tOwned[i]);
969
- delete node.tOwned;
970
- }
971
974
  reset(node, true);
972
975
  } else if (node.owned) {
973
976
  for (i = node.owned.length - 1; i >= 0; i--) cleanNode(node.owned[i]);
@@ -1334,7 +1337,7 @@ function mergeProps(...sources) {
1334
1337
  proxy = proxy || !!s && $PROXY in s;
1335
1338
  sources[i] = typeof s === "function" ? (proxy = true, createMemo(s)) : s;
1336
1339
  }
1337
- if (proxy) {
1340
+ if (SUPPORTS_PROXY && proxy) {
1338
1341
  return new Proxy({
1339
1342
  get(property) {
1340
1343
  for (let i = sources.length - 1; i >= 0; i--) {
@@ -1389,7 +1392,7 @@ function mergeProps(...sources) {
1389
1392
  return target;
1390
1393
  }
1391
1394
  function splitProps(props, ...keys) {
1392
- if ($PROXY in props) {
1395
+ if (SUPPORTS_PROXY && $PROXY in props) {
1393
1396
  const blocked = new Set(keys.length > 1 ? keys.flat() : keys[0]);
1394
1397
  const res = keys.map(k => {
1395
1398
  return new Proxy({
package/dist/dev.js CHANGED
@@ -119,6 +119,7 @@ function workLoop(hasTimeRemaining, initialTime) {
119
119
  const sharedConfig = {
120
120
  context: undefined,
121
121
  registry: undefined,
122
+ effects: undefined,
122
123
  done: false,
123
124
  getContextId() {
124
125
  return getContextId(this.context.count);
@@ -145,6 +146,7 @@ function nextHydrateContext() {
145
146
 
146
147
  const equalFn = (a, b) => a === b;
147
148
  const $PROXY = Symbol("solid-proxy");
149
+ const SUPPORTS_PROXY = typeof Proxy === "function";
148
150
  const $TRACK = Symbol("solid-track");
149
151
  const $DEVCOMP = Symbol("solid-dev-component");
150
152
  const signalOptions = {
@@ -998,13 +1000,14 @@ function runUserEffects(queue) {
998
1000
  sharedConfig.effects || (sharedConfig.effects = []);
999
1001
  sharedConfig.effects.push(...queue.slice(0, userLength));
1000
1002
  return;
1001
- } else if (sharedConfig.effects) {
1002
- queue = [...sharedConfig.effects, ...queue];
1003
- userLength += sharedConfig.effects.length;
1004
- delete sharedConfig.effects;
1005
1003
  }
1006
1004
  setHydrateContext();
1007
1005
  }
1006
+ if (sharedConfig.effects && (sharedConfig.done || !sharedConfig.count)) {
1007
+ queue = [...sharedConfig.effects, ...queue];
1008
+ userLength += sharedConfig.effects.length;
1009
+ delete sharedConfig.effects;
1010
+ }
1008
1011
  for (i = 0; i < userLength; i++) runTop(queue[i]);
1009
1012
  }
1010
1013
  function lookUpstream(node, ignore) {
@@ -1053,11 +1056,11 @@ function cleanNode(node) {
1053
1056
  }
1054
1057
  }
1055
1058
  }
1059
+ if (node.tOwned) {
1060
+ for (i = node.tOwned.length - 1; i >= 0; i--) cleanNode(node.tOwned[i]);
1061
+ delete node.tOwned;
1062
+ }
1056
1063
  if (Transition && Transition.running && node.pure) {
1057
- if (node.tOwned) {
1058
- for (i = node.tOwned.length - 1; i >= 0; i--) cleanNode(node.tOwned[i]);
1059
- delete node.tOwned;
1060
- }
1061
1064
  reset(node, true);
1062
1065
  } else if (node.owned) {
1063
1066
  for (i = node.owned.length - 1; i >= 0; i--) cleanNode(node.owned[i]);
@@ -1442,7 +1445,7 @@ function mergeProps(...sources) {
1442
1445
  proxy = proxy || (!!s && $PROXY in s);
1443
1446
  sources[i] = typeof s === "function" ? ((proxy = true), createMemo(s)) : s;
1444
1447
  }
1445
- if (proxy) {
1448
+ if (SUPPORTS_PROXY && proxy) {
1446
1449
  return new Proxy(
1447
1450
  {
1448
1451
  get(property) {
@@ -1507,7 +1510,7 @@ function mergeProps(...sources) {
1507
1510
  return target;
1508
1511
  }
1509
1512
  function splitProps(props, ...keys) {
1510
- if ($PROXY in props) {
1513
+ if (SUPPORTS_PROXY && $PROXY in props) {
1511
1514
  const blocked = new Set(keys.length > 1 ? keys.flat() : keys[0]);
1512
1515
  const res = keys.map(k => {
1513
1516
  return new Proxy(
package/dist/server.cjs CHANGED
@@ -579,7 +579,7 @@ function lazy(fn) {
579
579
  };
580
580
  const contexts = new Set();
581
581
  const wrap = props => {
582
- const id = sharedConfig.context.id.slice(0, -1);
582
+ const id = sharedConfig.context.id;
583
583
  let ref = sharedConfig.context.lazy[id];
584
584
  if (ref) p = ref;else load(id);
585
585
  if (p.resolved) return p.resolved(props);
package/dist/server.js CHANGED
@@ -607,7 +607,7 @@ function lazy(fn) {
607
607
  };
608
608
  const contexts = new Set();
609
609
  const wrap = props => {
610
- const id = sharedConfig.context.id.slice(0, -1);
610
+ const id = sharedConfig.context.id;
611
611
  let ref = sharedConfig.context.lazy[id];
612
612
  if (ref) p = ref;
613
613
  else load(id);
package/dist/solid.cjs CHANGED
@@ -119,6 +119,7 @@ function workLoop(hasTimeRemaining, initialTime) {
119
119
  const sharedConfig = {
120
120
  context: undefined,
121
121
  registry: undefined,
122
+ effects: undefined,
122
123
  done: false,
123
124
  getContextId() {
124
125
  return getContextId(this.context.count);
@@ -145,6 +146,7 @@ function nextHydrateContext() {
145
146
 
146
147
  const equalFn = (a, b) => a === b;
147
148
  const $PROXY = Symbol("solid-proxy");
149
+ const SUPPORTS_PROXY = typeof Proxy === "function";
148
150
  const $TRACK = Symbol("solid-track");
149
151
  const $DEVCOMP = Symbol("solid-dev-component");
150
152
  const signalOptions = {
@@ -870,13 +872,14 @@ function runUserEffects(queue) {
870
872
  sharedConfig.effects || (sharedConfig.effects = []);
871
873
  sharedConfig.effects.push(...queue.slice(0, userLength));
872
874
  return;
873
- } else if (sharedConfig.effects) {
874
- queue = [...sharedConfig.effects, ...queue];
875
- userLength += sharedConfig.effects.length;
876
- delete sharedConfig.effects;
877
875
  }
878
876
  setHydrateContext();
879
877
  }
878
+ if (sharedConfig.effects && (sharedConfig.done || !sharedConfig.count)) {
879
+ queue = [...sharedConfig.effects, ...queue];
880
+ userLength += sharedConfig.effects.length;
881
+ delete sharedConfig.effects;
882
+ }
880
883
  for (i = 0; i < userLength; i++) runTop(queue[i]);
881
884
  }
882
885
  function lookUpstream(node, ignore) {
@@ -921,11 +924,11 @@ function cleanNode(node) {
921
924
  }
922
925
  }
923
926
  }
927
+ if (node.tOwned) {
928
+ for (i = node.tOwned.length - 1; i >= 0; i--) cleanNode(node.tOwned[i]);
929
+ delete node.tOwned;
930
+ }
924
931
  if (Transition && Transition.running && node.pure) {
925
- if (node.tOwned) {
926
- for (i = node.tOwned.length - 1; i >= 0; i--) cleanNode(node.tOwned[i]);
927
- delete node.tOwned;
928
- }
929
932
  reset(node, true);
930
933
  } else if (node.owned) {
931
934
  for (i = node.owned.length - 1; i >= 0; i--) cleanNode(node.owned[i]);
@@ -1287,7 +1290,7 @@ function mergeProps(...sources) {
1287
1290
  proxy = proxy || !!s && $PROXY in s;
1288
1291
  sources[i] = typeof s === "function" ? (proxy = true, createMemo(s)) : s;
1289
1292
  }
1290
- if (proxy) {
1293
+ if (SUPPORTS_PROXY && proxy) {
1291
1294
  return new Proxy({
1292
1295
  get(property) {
1293
1296
  for (let i = sources.length - 1; i >= 0; i--) {
@@ -1342,7 +1345,7 @@ function mergeProps(...sources) {
1342
1345
  return target;
1343
1346
  }
1344
1347
  function splitProps(props, ...keys) {
1345
- if ($PROXY in props) {
1348
+ if (SUPPORTS_PROXY && $PROXY in props) {
1346
1349
  const blocked = new Set(keys.length > 1 ? keys.flat() : keys[0]);
1347
1350
  const res = keys.map(k => {
1348
1351
  return new Proxy({
package/dist/solid.js CHANGED
@@ -119,6 +119,7 @@ function workLoop(hasTimeRemaining, initialTime) {
119
119
  const sharedConfig = {
120
120
  context: undefined,
121
121
  registry: undefined,
122
+ effects: undefined,
122
123
  done: false,
123
124
  getContextId() {
124
125
  return getContextId(this.context.count);
@@ -145,6 +146,7 @@ function nextHydrateContext() {
145
146
 
146
147
  const equalFn = (a, b) => a === b;
147
148
  const $PROXY = Symbol("solid-proxy");
149
+ const SUPPORTS_PROXY = typeof Proxy === "function";
148
150
  const $TRACK = Symbol("solid-track");
149
151
  const $DEVCOMP = Symbol("solid-dev-component");
150
152
  const signalOptions = {
@@ -941,13 +943,14 @@ function runUserEffects(queue) {
941
943
  sharedConfig.effects || (sharedConfig.effects = []);
942
944
  sharedConfig.effects.push(...queue.slice(0, userLength));
943
945
  return;
944
- } else if (sharedConfig.effects) {
945
- queue = [...sharedConfig.effects, ...queue];
946
- userLength += sharedConfig.effects.length;
947
- delete sharedConfig.effects;
948
946
  }
949
947
  setHydrateContext();
950
948
  }
949
+ if (sharedConfig.effects && (sharedConfig.done || !sharedConfig.count)) {
950
+ queue = [...sharedConfig.effects, ...queue];
951
+ userLength += sharedConfig.effects.length;
952
+ delete sharedConfig.effects;
953
+ }
951
954
  for (i = 0; i < userLength; i++) runTop(queue[i]);
952
955
  }
953
956
  function lookUpstream(node, ignore) {
@@ -996,11 +999,11 @@ function cleanNode(node) {
996
999
  }
997
1000
  }
998
1001
  }
1002
+ if (node.tOwned) {
1003
+ for (i = node.tOwned.length - 1; i >= 0; i--) cleanNode(node.tOwned[i]);
1004
+ delete node.tOwned;
1005
+ }
999
1006
  if (Transition && Transition.running && node.pure) {
1000
- if (node.tOwned) {
1001
- for (i = node.tOwned.length - 1; i >= 0; i--) cleanNode(node.tOwned[i]);
1002
- delete node.tOwned;
1003
- }
1004
1007
  reset(node, true);
1005
1008
  } else if (node.owned) {
1006
1009
  for (i = node.owned.length - 1; i >= 0; i--) cleanNode(node.owned[i]);
@@ -1378,7 +1381,7 @@ function mergeProps(...sources) {
1378
1381
  proxy = proxy || (!!s && $PROXY in s);
1379
1382
  sources[i] = typeof s === "function" ? ((proxy = true), createMemo(s)) : s;
1380
1383
  }
1381
- if (proxy) {
1384
+ if (SUPPORTS_PROXY && proxy) {
1382
1385
  return new Proxy(
1383
1386
  {
1384
1387
  get(property) {
@@ -1443,7 +1446,7 @@ function mergeProps(...sources) {
1443
1446
  return target;
1444
1447
  }
1445
1448
  function splitProps(props, ...keys) {
1446
- if ($PROXY in props) {
1449
+ if (SUPPORTS_PROXY && $PROXY in props) {
1447
1450
  const blocked = new Set(keys.length > 1 ? keys.flat() : keys[0]);
1448
1451
  const res = keys.map(k => {
1449
1452
  return new Proxy(
package/h/dist/h.cjs CHANGED
@@ -23,7 +23,7 @@ function createHyperScript(r) {
23
23
  const type = typeof l;
24
24
  if (l == null) ;else if ("string" === type) {
25
25
  if (!e) parseClass(l);else e.appendChild(document.createTextNode(l));
26
- } else if ("number" === type || "boolean" === type || l instanceof Date || l instanceof RegExp) {
26
+ } else if ("number" === type || "boolean" === type || "bigint" === type || "symbol" === type || l instanceof Date || l instanceof RegExp) {
27
27
  e.appendChild(document.createTextNode(l.toString()));
28
28
  } else if (Array.isArray(l)) {
29
29
  for (let i = 0; i < l.length; i++) item(l[i]);
package/h/dist/h.js CHANGED
@@ -33,6 +33,8 @@ function createHyperScript(r) {
33
33
  } else if (
34
34
  "number" === type ||
35
35
  "boolean" === type ||
36
+ "bigint" === type ||
37
+ "symbol" === type ||
36
38
  l instanceof Date ||
37
39
  l instanceof RegExp
38
40
  ) {
@@ -1017,6 +1017,8 @@ export namespace JSX {
1017
1017
  src?: FunctionMaybe<string>;
1018
1018
  srcset?: FunctionMaybe<string>;
1019
1019
  type?: FunctionMaybe<string>;
1020
+ width?: FunctionMaybe<number | string>;
1021
+ height?: FunctionMaybe<number | string>;
1020
1022
  }
1021
1023
  interface StyleHTMLAttributes<T> extends HTMLAttributes<T> {
1022
1024
  media?: FunctionMaybe<string>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "solid-js",
3
3
  "description": "A declarative JavaScript library for building user interfaces.",
4
- "version": "1.8.21",
4
+ "version": "1.8.23",
5
5
  "author": "Ryan Carniato",
6
6
  "license": "MIT",
7
7
  "homepage": "https://solidjs.com",
@@ -282,7 +282,7 @@ function wrap(value) {
282
282
  const keys = Object.keys(value),
283
283
  desc = Object.getOwnPropertyDescriptors(value);
284
284
  const proto = Object.getPrototypeOf(value);
285
- const isClass = value !== null && typeof value === "object" && !Array.isArray(value) && proto !== Object.prototype;
285
+ const isClass = proto !== null && value !== null && typeof value === "object" && !Array.isArray(value) && proto !== Object.prototype;
286
286
  if (isClass) {
287
287
  const descriptors = Object.getOwnPropertyDescriptors(proto);
288
288
  keys.push(...Object.keys(descriptors));
package/store/dist/dev.js CHANGED
@@ -324,6 +324,7 @@ function wrap(value) {
324
324
  desc = Object.getOwnPropertyDescriptors(value);
325
325
  const proto = Object.getPrototypeOf(value);
326
326
  const isClass =
327
+ proto !== null &&
327
328
  value !== null &&
328
329
  typeof value === "object" &&
329
330
  !Array.isArray(value) &&
@@ -271,7 +271,7 @@ function wrap(value) {
271
271
  const keys = Object.keys(value),
272
272
  desc = Object.getOwnPropertyDescriptors(value);
273
273
  const proto = Object.getPrototypeOf(value);
274
- const isClass = value !== null && typeof value === "object" && !Array.isArray(value) && proto !== Object.prototype;
274
+ const isClass = proto !== null && value !== null && typeof value === "object" && !Array.isArray(value) && proto !== Object.prototype;
275
275
  if (isClass) {
276
276
  const descriptors = Object.getOwnPropertyDescriptors(proto);
277
277
  keys.push(...Object.keys(descriptors));
@@ -310,6 +310,7 @@ function wrap(value) {
310
310
  desc = Object.getOwnPropertyDescriptors(value);
311
311
  const proto = Object.getPrototypeOf(value);
312
312
  const isClass =
313
+ proto !== null &&
313
314
  value !== null &&
314
315
  typeof value === "object" &&
315
316
  !Array.isArray(value) &&
package/types/jsx.d.ts CHANGED
@@ -270,23 +270,16 @@ export namespace JSX {
270
270
  onPointerOut?: EventHandlerUnion<T, PointerEvent> | undefined;
271
271
  onPointerOver?: EventHandlerUnion<T, PointerEvent> | undefined;
272
272
  onPointerUp?: EventHandlerUnion<T, PointerEvent> | undefined;
273
- onProgress?: EventHandlerUnion<T, Event> | undefined;
273
+ onProgress?: EventHandlerUnion<T, ProgressEvent> | undefined;
274
274
  onRateChange?: EventHandlerUnion<T, Event> | undefined;
275
275
  onReset?: EventHandlerUnion<T, Event> | undefined;
276
276
  onScroll?: EventHandlerUnion<T, Event> | undefined;
277
277
  onScrollEnd?: EventHandlerUnion<T, Event> | undefined;
278
278
  onSeeked?: EventHandlerUnion<T, Event> | undefined;
279
279
  onSeeking?: EventHandlerUnion<T, Event> | undefined;
280
- onSelect?: EventHandlerUnion<T, UIEvent> | undefined;
280
+ onSelect?: EventHandlerUnion<T, Event> | undefined;
281
281
  onStalled?: EventHandlerUnion<T, Event> | undefined;
282
- onSubmit?:
283
- | EventHandlerUnion<
284
- T,
285
- Event & {
286
- submitter: HTMLElement;
287
- }
288
- >
289
- | undefined;
282
+ onSubmit?: EventHandlerUnion<T, SubmitEvent> | undefined;
290
283
  onSuspend?: EventHandlerUnion<T, Event> | undefined;
291
284
  onTimeUpdate?: EventHandlerUnion<T, Event> | undefined;
292
285
  onToggle?: EventHandlerUnion<T, ToggleEvent> | undefined;
@@ -361,21 +354,16 @@ export namespace JSX {
361
354
  onpointerout?: EventHandlerUnion<T, PointerEvent> | undefined;
362
355
  onpointerover?: EventHandlerUnion<T, PointerEvent> | undefined;
363
356
  onpointerup?: EventHandlerUnion<T, PointerEvent> | undefined;
364
- onprogress?: EventHandlerUnion<T, Event> | undefined;
357
+ onprogress?: EventHandlerUnion<T, ProgressEvent> | undefined;
365
358
  onratechange?: EventHandlerUnion<T, Event> | undefined;
366
359
  onreset?: EventHandlerUnion<T, Event> | undefined;
367
360
  onscroll?: EventHandlerUnion<T, Event> | undefined;
368
361
  onscrollend?: EventHandlerUnion<T, Event> | undefined;
369
362
  onseeked?: EventHandlerUnion<T, Event> | undefined;
370
363
  onseeking?: EventHandlerUnion<T, Event> | undefined;
371
- onselect?: EventHandlerUnion<T, UIEvent> | undefined;
364
+ onselect?: EventHandlerUnion<T, Event> | undefined;
372
365
  onstalled?: EventHandlerUnion<T, Event> | undefined;
373
- onsubmit?: EventHandlerUnion<
374
- T,
375
- Event & {
376
- submitter: HTMLElement;
377
- }
378
- >;
366
+ onsubmit?: EventHandlerUnion<T, SubmitEvent> | undefined;
379
367
  onsuspend?: EventHandlerUnion<T, Event> | undefined;
380
368
  ontimeupdate?: EventHandlerUnion<T, Event> | undefined;
381
369
  ontoggle?: EventHandlerUnion<T, ToggleEvent> | undefined;
@@ -612,7 +600,8 @@ export namespace JSX {
612
600
  | "removals text"
613
601
  | "text"
614
602
  | "text additions"
615
- | "text removals";
603
+ | "text removals"
604
+ | undefined;
616
605
  /** Indicates that user input is required on the element before a form may be submitted. */
617
606
  "aria-required"?: boolean | "false" | "true" | undefined;
618
607
  /** Defines a human-readable, author-localized description for the role of an element. */
@@ -725,7 +714,8 @@ export namespace JSX {
725
714
  | "tooltip"
726
715
  | "tree"
727
716
  | "treegrid"
728
- | "treeitem";
717
+ | "treeitem"
718
+ | undefined;
729
719
  }
730
720
 
731
721
  // TODO: Should we allow this?
@@ -1135,6 +1125,8 @@ export namespace JSX {
1135
1125
  src?: string | undefined;
1136
1126
  srcset?: string | undefined;
1137
1127
  type?: string | undefined;
1128
+ width?: number | string | undefined;
1129
+ height?: number | string | undefined;
1138
1130
  }
1139
1131
  interface StyleHTMLAttributes<T> extends HTMLAttributes<T> {
1140
1132
  media?: string | undefined;
@@ -1322,7 +1314,8 @@ export namespace JSX {
1322
1314
  | "alphabetic"
1323
1315
  | "hanging"
1324
1316
  | "mathematical"
1325
- | "inherit";
1317
+ | "inherit"
1318
+ | undefined;
1326
1319
  "baseline-shift"?: number | string | undefined;
1327
1320
  clip?: string | undefined;
1328
1321
  "clip-path"?: string | undefined;
@@ -1345,7 +1338,8 @@ export namespace JSX {
1345
1338
  | "mathematical"
1346
1339
  | "hanging"
1347
1340
  | "text-top"
1348
- | "inherit";
1341
+ | "inherit"
1342
+ | undefined;
1349
1343
  "enable-background"?: string | undefined;
1350
1344
  fill?: string | undefined;
1351
1345
  "fill-opacity"?: number | string | "inherit" | undefined;
@@ -1385,7 +1379,8 @@ export namespace JSX {
1385
1379
  | "stroke"
1386
1380
  | "all"
1387
1381
  | "none"
1388
- | "inherit";
1382
+ | "inherit"
1383
+ | undefined;
1389
1384
  "shape-rendering"?:
1390
1385
  | "auto"
1391
1386
  | "optimizeSpeed"
@@ -1417,7 +1412,8 @@ export namespace JSX {
1417
1412
  | "optimizeSpeed"
1418
1413
  | "optimizeLegibility"
1419
1414
  | "geometricPrecision"
1420
- | "inherit";
1415
+ | "inherit"
1416
+ | undefined;
1421
1417
  "unicode-bidi"?: string | undefined;
1422
1418
  visibility?: "visible" | "hidden" | "collapse" | "inherit" | undefined;
1423
1419
  "word-spacing"?: number | string | undefined;
@@ -2113,7 +2109,7 @@ export namespace JSX {
2113
2109
  main: HTMLAttributes<HTMLElement>;
2114
2110
  map: MapHTMLAttributes<HTMLMapElement>;
2115
2111
  mark: HTMLAttributes<HTMLElement>;
2116
- menu: MenuHTMLAttributes<HTMLElement>;
2112
+ menu: MenuHTMLAttributes<HTMLMenuElement>;
2117
2113
  meta: MetaHTMLAttributes<HTMLMetaElement>;
2118
2114
  meter: MeterHTMLAttributes<HTMLElement>;
2119
2115
  nav: HTMLAttributes<HTMLElement>;
@@ -26,6 +26,7 @@ import type { JSX } from "../jsx.js";
26
26
  import type { FlowComponent } from "../render/index.js";
27
27
  export declare const equalFn: <T>(a: T, b: T) => boolean;
28
28
  export declare const $PROXY: unique symbol;
29
+ export declare const SUPPORTS_PROXY: boolean;
29
30
  export declare const $TRACK: unique symbol;
30
31
  export declare const $DEVCOMP: unique symbol;
31
32
  export declare var Owner: Owner | null;
@@ -494,7 +495,7 @@ export interface OnOptions {
494
495
  * });
495
496
  * ```
496
497
  *
497
- * @description https://docs.solidjs.com/reference/jsx-attributes/on_
498
+ * @description https://docs.solidjs.com/reference/reactive-utilities/on
498
499
  */
499
500
  export declare function on<S, Next extends Prev, Prev = Next>(
500
501
  deps: AccessorArray<S> | Accessor<S>,
@@ -557,6 +558,7 @@ export type Transition = [Accessor<boolean>, (fn: () => void) => Promise<void>];
557
558
  * () => boolean,
558
559
  * (fn: () => void, cb?: () => void) => void
559
560
  * ];
561
+ * ```
560
562
  * @returns a tuple; first value is an accessor if the transition is pending and a callback to start the transition
561
563
  *
562
564
  * @description https://docs.solidjs.com/reference/reactive-utilities/use-transition
package/web/dist/dev.cjs CHANGED
@@ -322,6 +322,7 @@ function runHydrationEvents() {
322
322
  completed,
323
323
  events
324
324
  } = solidJs.sharedConfig;
325
+ if (!events) return;
325
326
  events.queued = false;
326
327
  while (events.length) {
327
328
  const [el, e] = events[0];
package/web/dist/dev.js CHANGED
@@ -780,6 +780,7 @@ function runHydrationEvents() {
780
780
  if (sharedConfig.events && !sharedConfig.events.queued) {
781
781
  queueMicrotask(() => {
782
782
  const { completed, events } = sharedConfig;
783
+ if (!events) return;
783
784
  events.queued = false;
784
785
  while (events.length) {
785
786
  const [el, e] = events[0];
@@ -50,7 +50,7 @@ function renderToString(code, options = {}) {
50
50
  if (!scripts) {
51
51
  scripts = getLocalHeaderScript(renderId);
52
52
  }
53
- scripts += script;
53
+ scripts += script + ";";
54
54
  },
55
55
  onError: options.onError
56
56
  });
@@ -104,7 +104,7 @@ function renderToString(code, options = {}) {
104
104
  if (!scripts) {
105
105
  scripts = getLocalHeaderScript(renderId);
106
106
  }
107
- scripts += script;
107
+ scripts += script + ";";
108
108
  },
109
109
  onError: options.onError
110
110
  });
package/web/dist/web.cjs CHANGED
@@ -317,6 +317,7 @@ function runHydrationEvents() {
317
317
  completed,
318
318
  events
319
319
  } = solidJs.sharedConfig;
320
+ if (!events) return;
320
321
  events.queued = false;
321
322
  while (events.length) {
322
323
  const [el, e] = events[0];
package/web/dist/web.js CHANGED
@@ -768,6 +768,7 @@ function runHydrationEvents() {
768
768
  if (sharedConfig.events && !sharedConfig.events.queued) {
769
769
  queueMicrotask(() => {
770
770
  const { completed, events } = sharedConfig;
771
+ if (!events) return;
771
772
  events.queued = false;
772
773
  while (events.length) {
773
774
  const [el, e] = events[0];