diff --git a/.changeset/pre.json b/.changeset/pre.json index b56c6f7dc..c2e5c00ea 100644 --- a/.changeset/pre.json +++ b/.changeset/pre.json @@ -27,6 +27,7 @@ }, "changesets": [ "a28-writes-visible-at-flush", + "abandoned-loading-pass-yields-fragment", "abortsignal-types-no-dom", "absorb-expressions", "accept-empty-server-function-posts", @@ -47,6 +48,7 @@ "adopt-runtime-wire-protocols", "adopted-recall-claim-gate", "adopted-slot-range-stays-live", + "adopted-zombie-follows-lane", "affects-captured-proxy-scope", "affects-single-key", "afraid-queens-divide", @@ -80,11 +82,15 @@ "audit-driver-family-decline-multi-slot", "avoid-reconcile-key-recompute", "awaitable-refresh", + "babel-plugin-ssr-hoist-props-ts-types", "bare-client-source-suspends-as-final-hole", "behavior-claims-delegate-glue", "behavior-claims-props", "bind-get-grants-to-function-identity", + "binding-slot-execution", + "binding-slot-text-positions", "body-end-visibility", + "born-held-effect-lane-run-restages", "born-held", "bound-body-by-bytes-received", "bound-server-function-requests", @@ -106,6 +112,7 @@ "bump-dom-expressions-next-5", "bump-dom-expressions-next-8", "carry-live-get-grant-across-dev-rebind", + "chunk-reader-hardening", "clarify-invoke-wrapper-contract", "clean-bikes-teach", "cleanup-unwind-order", @@ -121,17 +128,26 @@ "commit-clears-transition-stamp", "companion-oracle-census", "companion-shadow-redesign", + "compiler-clippy-rustfmt-cleanup", "compiler-component-names", + "compiler-coverage-pragmas", "compiler-loader-accepts-patch-driver", "compiler-loader-prefer-local-build", "compiler-server-components-attribute-slot-positions", + "compiler-source-locations", "compiler-source-names-bindings", "compiler-source-names-option", "compiler-source-names-primitives", "compiler-spread-sources-array", + "compiler-ssr-capture-source-locations", + "compiler-ssr-hoist-props-ts-types", + "compiler-unicode-diagnostics", + "compiler-wasi-android-root", "composed-header-bounds-transport", + "const-effect-tuple-inference", "contain-flight-collector-errors", "container-tier-projection-traces", + "container-trace-claim-reads-snapshot", "context-default-less-throws", "continue-tsrx-semantic-ir", "core-hot-path-shape-alignment", @@ -150,7 +166,13 @@ "deprecate-create-tracked-effect", "deprecate-dynamic-component", "deprecate-server-writes", + "derive-reads-held-key-joins", + "derived-optimistic-writer-frame", + "derived-store-retained-draft-row", + "derived-writes-apply-before-derivations", "dev-artifact-naming", + "dev-cost-checks-plumbing-exempt", + "dev-cost-checks-tracks-records-only", "dev-error-invalid-refresh-target", "dev-error-non-function-component", "dev-error-untracked-async-read", @@ -163,6 +185,7 @@ "diagnostic-code-consolidation", "diagnostic-code-prefix", "diagnostic-console-footers", + "diagnostic-guide-sections", "diagnostics-console-addressability", "diagnostics-engine-release-token", "diagnostics-fanout-repair-projection", @@ -187,6 +210,7 @@ "dynamic-factory-redesign", "dynamic-remount-latest-address", "dynamic-run-hydration-events", + "dynamic-spread-attributes-before-children", "dynamic-static-source", "dynamic-xmlns-namespace", "effect-cleanup-unwind-order", @@ -205,6 +229,7 @@ "enforce-provide-event-single-invocation", "error-hook-thrower-path", "errored-fallback-thunk-scope", + "errored-pass-tail-still-observes", "export-memo-options", "expose-enableExternalSource-loading-on", "extract-nested-server-function-declarations", @@ -213,6 +238,7 @@ "feedback-findings", "fetch-option-retry-contract", "fill-cleanup-occurrence-scope", + "first-load-lands-into-hold", "fix-absorbed-compiler-parity", "fix-action-falsy-generator-throw", "fix-action-thenable-await", @@ -299,6 +325,7 @@ "fix-frames-web-path-mapping", "fix-get-grant-lifetime-and-read-folding", "fix-get-request-event-cross-request", + "fix-graph-growth-initial-declaration", "fix-halt-error-swallow", "fix-held-conditional-effect", "fix-held-conditional-memo", @@ -312,6 +339,7 @@ "fix-hydration-and-signals-baseline", "fix-hydration-latched-divergence-lost", "fix-hydration-trace-foreign-iterable", + "fix-hydration-trace-promise-statics", "fix-insert-sibling-rerender", "fix-insert-text-node-reuse", "fix-ispending-dev-prod-divergence", @@ -372,6 +400,7 @@ "fix-optimistic-move-duplicate-3548", "fix-optimistic-override-premature-revert", "fix-optimistic-read-lane-not-transaction", + "fix-optimistic-removed-prop-read", "fix-optimistic-same-value-overlap", "fix-optimistic-settle-verdicts", "fix-optimistic-store-layer-scope", @@ -383,6 +412,7 @@ "fix-override-supersession-on-arrival", "fix-owned-write-guard-docs", "fix-ownerless-conditional-memos", + "fix-parenthesized-tsrx-keys", "fix-pending-autodispose-release", "fix-pending-companion-lane-parent", "fix-pending-gated-landing-replay", @@ -467,6 +497,7 @@ "fix-ssr-escape-function-results", "fix-ssr-loading-errored-hydration", "fix-ssr-memo-promise-notready", + "fix-ssr-nullish-attributes", "fix-ssr-owner-id-parity", "fix-ssr-owner-pool-stale-links", "fix-ssr-post-render-rejection-3570", @@ -478,6 +509,7 @@ "fix-ssr-spread-children-read-once", "fix-ssr-stream-bare-child-rejection-3569", "fix-ssr-stream-rejected-fragment-hang", + "fix-ssr-style-object-separators", "fix-ssr-sync-memo-child-id-leak", "fix-ssr-text-separators-resolved", "fix-ssr-textarea-spread-value", @@ -516,10 +548,12 @@ "fix-tsrx-index-loop-mode", "fix-tsrx-lazy-update-rewrites", "fix-tsrx-release-expansion-stack", + "fix-tsrx-setup-semicolon", "fix-universal-text-escaping", "fix-usehead-prelude-hydration-walk", "fix-usehead-stylesheet-hydration", "fix-validate-document-shell", + "fix-verdict-lane-flush-loop", "fix-version-skew-label-before-gate", "fix-zombie-flag-survives-recompute", "flash-falsy-nojs-outcomes", @@ -532,24 +566,55 @@ "format-ssr-hydration-followups", "fragment-ledger-one-reveal-owner", "fragment-reveal-policy-registry", + "fragment-stylesheet-gate", "frame-conditional-reconnect", "frame-scope-projection-pump", "frame-teardown-on-disconnect", + "frames-a1b-stage-deletion-s-ref", + "frames-a3-reveal-applies-its-range", + "frames-a4-declared-slot-records", + "frames-a5-fragment-ownership-by-rendering", + "frames-a7-error-throws-reset-reasks", + "frames-address-source", + "frames-assets-tier", "frames-attribute-slots", + "frames-bind-tier", + "frames-c12-fragment-error-outcome", + "frames-c13-sweep-ops-chunk", + "frames-claim-through-hydrate-window", "frames-client-externalize-wire-layer", "frames-consume-live", + "frames-data-response-scoped", + "frames-drop-dead-slot-nodes-writes", "frames-dynamic-handoff", "frames-element-seams", + "frames-fragment-rejection-report", + "frames-hold-is-pending-boundary", "frames-identity-split", "frames-lazy-codec-and-op-log-compaction", "frames-live-document-face", "frames-live-slot-props-binding", + "frames-live-wire-tier", + "frames-plain-response-bound", + "frames-rebind-in-the-pass", + "frames-refetch-lands-at-commit", + "frames-regions-tier", + "frames-residue-1-d-list", + "frames-residue-1-have-constants", + "frames-residue-1-lean-reask", + "frames-residue-3-every-fill-through-insert", + "frames-residue-4-sref-table", "frames-server-components-experimental", "frames-showing-refetch-settles-on-apply", "frames-single-flight-wiring", + "frames-slot-arg-abandoned-flights", "frames-slot-claim-handover", "frames-slot-type", + "frames-tier-mechanism", + "frames-trace-update-site-wait", + "frames-traces-tier", "freeze-awaited-render-head", + "fresh-loading-fallback-in-flush", "fuzzy-queens-retire", "gate-child-companion-walk", "gate-invariants-to-test-builds", @@ -562,6 +627,7 @@ "guard-error-carried-failure-channels", "guard-failures-iterative-walk", "guard-getter-and-map-key-channels", + "h-rematerialize-without-mutating-props", "halt-reactivity-on-uncaught-error", "handle-async-setter-errors", "head-shell-hold-probe-seam", @@ -573,12 +639,16 @@ "hold-consistency-batch-2", "hot-scope-fanout-aggregation", "html-braced-comments", + "html-component-on-prop-getters", "html-element-claims", + "html-self-closing-raw-text", "hydrate-claim-path", "hydrating-root-snapshot-scope", "hydrating-store-engine-seam", "hydration-latch-outside-pending-boundaries", + "hydration-late-claim-keeps-nodes-in-place", "hydration-null-owner-hybrid-latch", + "hydration-payload-owns-record-rejections", "hydration-primitive-wrappers", "hydration-write-time-snapshot", "identity-keyed-server-function-ids", @@ -588,6 +658,7 @@ "improve-tsrx-lazy-destructuring", "include-web-cookie-declarations", "initial-route-declaration", + "interaction-frame-per-event", "internal-surface-followup", "internal-view-protocol-surface", "inv2-active-override-assertion", @@ -599,13 +670,22 @@ "iterate-bare-step-tolerance", "iterator-supersede-eager-close", "jfb-driver-and-write-bound", + "joined-slot-adopts-answer", "jsx-key-intrinsic-typing", "keep-ambient-batch-on-stash", "keep-negative-zero-off-the-json-fast-path", + "l2-fuzz-existing-rules", "label-version-skew-404", + "landing-rejudges-parked-transactions", "lane-drop-dead-companion-refresh", "lane-frame-children-3662", "lane-hold-on-observation", + "lane-holds-through-boundary-content", + "lane-mount-binding-reads-screen", + "lane-mount-boundary-over-flight", + "lane-node-in-held-frame-stays-the-lanes", + "lane-stale-reader-unheld-lane", + "lane-takeover-held-effect", "late-boundary-held-fragment-wait", "latest-lazy-companion-backfill", "latest-probe-order-independence", @@ -633,6 +713,7 @@ "live-retryable-4xx-and-retry-after", "live-return-completes-nested", "live-source-auto-hybrid", + "live-takeover-streaming-value", "live-takeover-yields-adopted-value", "loading-errored-composition-escape", "loading-on-follows-frame", @@ -646,6 +727,7 @@ "loading-window-verdict-quiet-through-hydration", "lone-spread-no-merge", "long-hold-and-stricter-thresholds", + "lowercase-on-is-attribute", "maparray-nonkeyed-store-stale-row", "maparray-small-move-fast-path", "maparray-swap-commit", @@ -684,6 +766,8 @@ "optimistic-lists-drivable", "optimistic-mask-effective-writes-only", "optimistic-mask-ispending", + "optimistic-over-held-row", + "optimistic-retained-draft-row", "optimistic-reverted", "optimistic-store-first-flight-no-transaction", "optimistic-undeclared-flight-owner", @@ -762,6 +846,7 @@ "reconcile-array-object-shape-guard", "reconcile-default-id-positional-null", "reconcile-symbol-keyed-nodes", + "reconcile-unchanged-presence-no-hold", "reconcile-walk-guard-hoist", "recover-from-halt-in-dev-workflows", "recover-tsrx-editor-snapshots", @@ -798,6 +883,7 @@ "remove-create-effect-single-argument-overload", "remove-derived-initial-values", "remove-dist-exports-and-fix-dual-types", + "remove-empty-signals-reexport", "remove-initial-ssr-source", "remove-isrefreshing-api", "remove-loading-notify-through-remap", @@ -814,11 +900,13 @@ "renderer-owned-jsx-types", "repeat-disjoint-window", "republish-fresh-signals-build", + "request-failure-report", "require-client-source-commit-zero", "require-seroval-1-5-4", "require-seroval-1-6", "response-head-lifecycle", "responsive-preload-links", + "restaged-effect-no-early-run", "reveal-order-prop", "reveal-ssr-streaming-support", "reveal-string-ssr-collapsed", @@ -836,6 +924,7 @@ "scope-property-read-holes", "serialization-decode-entry", "serve-one-slow-selection", + "server-async-iterable-slot-memory", "server-boundary-records", "server-component-context-barrier", "server-dev-build", @@ -865,6 +954,7 @@ "server-store-replacement-optimistic-noop", "server-trace-context", "setter-row-ops-tentative-lists", + "settle-fast-path", "settle-superseded-flight-dependents", "settle-unchanged-pending-branches", "settle-walk-dev-invariant", @@ -886,6 +976,30 @@ "simplify-render-wrappers", "single-flight-keyed-envelope-only", "single-flight-protocol-bridge", + "single-flight-settle-streamed-slices", + "size-affects-on-l2", + "size-attribution-on-l2", + "size-audit-l2-hold-model", + "size-carve-lane-layer", + "size-lane-layer-s0", + "size-lane-layer-s1", + "size-lane-layer-s2", + "size-spec-l2-hold-model", + "size-store-bench-fixes-2", + "size-store-bench-fixes", + "size-store-container-node-escape-hatch", + "size-store-prebatch-backing", + "size-stores-on-l2-s3c", + "size-stores-qd-parity", + "size-stores-qd-provenance", + "size-stores-s1-plain", + "size-stores-s2-holds", + "size-stores-s3a-projections", + "size-stores-s3b-held-derived", + "size-stores-s4-optimistic", + "size-stores-s4-seam-trim", + "size-stores-s5-affects", + "size-stores-su-utils", "skip-sync-noop-status-work", "slot-jsx-convention-docs", "slot-signal-creation-diet", @@ -900,6 +1014,7 @@ "spread-direct-sources", "spread-fewer-nodes", "ssr-boundary-resolve-scope-3414", + "ssr-capture-source-locations", "ssr-component-names", "ssr-element-attrs-and-merge-read-path", "ssr-element-join-in-place", @@ -908,12 +1023,17 @@ "ssr-falsy-rejections-and-thenables", "ssr-hole-id-scopes", "ssr-props-hoisted-constructors", + "ssr-response-settles-pre-shell", + "ssr-response-teardown-on-cancel-and-redirect", "ssr-retry-robustness", "ssr-scope-lazy-id", "ssr-shared-async-sources", + "ssr-shell-suspend-retry", + "ssr-shell-suspend-serializer-flush", "ssr-spread-static-tail", "ssr-spread-static-text-escape", "ssr-spread-walk-hot-path", + "ssr-validate-dynamic-names", "ssrSource-effects-and-fix-server-createEffect", "ssrsource-async-iterables", "staged-reporter-deps-tail", @@ -927,6 +1047,7 @@ "store-descriptor-trap-subscribes", "store-enumerator-presence-nodes-3664", "store-first-read-diet", + "store-fold-queue-prebatch-record", "store-hold-visible", "store-hot-path-trims", "store-next-settled-visibility", @@ -991,6 +1112,7 @@ "universal-renderer-effect-names", "universal-spread-sources", "unstable-list-identity", + "unstable-memo-symbol-keys", "until-flip-entanglement", "until-live-source-ack", "untracked-async-handler", @@ -1012,13 +1134,19 @@ "update-signals-bugfix-baseline", "validate-malformed-html-error", "validate-prepare-request-return", + "verdict-mount-first-pass-mainline", + "verdict-pull-outside-window", + "verdict-reader-first-observer-holds-the-flight", + "verdict-reader-silent-landing", "view-table-on-enumeration", "violet-stingrays-end", "wait-asset-seam", "wake-synchronously-settled-transactions", "warm-doors-flow", + "wasted-recompute-undefined-output", "wasted-recompute", "web-commit-event-response", + "web-dynamic-component", "web-feature-folders", "web-http-declaration-ledger", "web-lazy-serializer-split", @@ -1027,6 +1155,7 @@ "web-request-event-locals", "web-serialization-create-plugin", "web-server-dist-prod-mode", + "web-server-entry-treeshaking", "why-did-this-run-attribution", "woken-transaction-staged-bump", "write-proposals-3494", diff --git a/examples/todos-server/CHANGELOG.md b/examples/todos-server/CHANGELOG.md index eaf4a66e7..864751225 100644 --- a/examples/todos-server/CHANGELOG.md +++ b/examples/todos-server/CHANGELOG.md @@ -1,5 +1,70 @@ # todos-server-example +## 0.0.1-rc.2 + +### Patch Changes + +- Updated dependencies [4b4c2cb] +- Updated dependencies [ecb68a1] +- Updated dependencies [d4b10b5] +- Updated dependencies [2eb6e00] +- Updated dependencies [21ff8f8] +- Updated dependencies [3c1d512] +- Updated dependencies [9a213bb] +- Updated dependencies [721eb06] +- Updated dependencies [b0c6e6a] +- Updated dependencies [365f37d] +- Updated dependencies [da84bd9] +- Updated dependencies [98d35b9] +- Updated dependencies [b57eb2e] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [9d89df7] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [3c1d512] +- Updated dependencies [1b9ceb6] +- Updated dependencies [203ab1a] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [3c7631a] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [e44b2e4] +- Updated dependencies [01e80a6] +- Updated dependencies [be82cf3] +- Updated dependencies [759a9b6] +- Updated dependencies [e345dc7] +- Updated dependencies [4f67697] +- Updated dependencies [41fdf96] +- Updated dependencies [87a3862] +- Updated dependencies [53ef0e6] +- Updated dependencies [2656284] +- Updated dependencies [9338c00] +- Updated dependencies [7addcc6] +- Updated dependencies [6f77b1b] +- Updated dependencies [537e945] +- Updated dependencies [7233451] +- Updated dependencies [8d66ae5] + - solid-js@2.0.0-rc.14 + - @solidjs/web@2.0.0-rc.14 + ## 0.0.1-rc.1 ### Patch Changes diff --git a/examples/todos-server/package.json b/examples/todos-server/package.json index 7c362608f..199daa9d2 100644 --- a/examples/todos-server/package.json +++ b/examples/todos-server/package.json @@ -1,7 +1,7 @@ { "name": "todos-server-example", "description": "TodoMVC as a Solid Server Component — the list is server markup, and every optimistic behavior (toggle, remove, pending/error/retry, counts, filters) is a client fill over slot args and createOptimisticStore state: binding slots the server template reads at positions, a shared TodoRow on both sides, one markup slot for pending adds", - "version": "0.0.1-rc.1", + "version": "0.0.1-rc.2", "private": true, "author": "Ryan Carniato", "license": "MIT", diff --git a/packages/babel-plugin/CHANGELOG.md b/packages/babel-plugin/CHANGELOG.md index 67a3ab4e6..6ec6a26c1 100644 --- a/packages/babel-plugin/CHANGELOG.md +++ b/packages/babel-plugin/CHANGELOG.md @@ -1,5 +1,22 @@ # @solidjs/babel-plugin +## 2.0.0-rc.14 + +### Patch Changes + +- 59fb244: SSR `hoistProps` skips TypeScript type positions when collecting captures, so on authored TSX (types parsed, stripped later) a `typeof x` query or a type named like a value no longer captures that value, or forces the literal fallback when it is reassigned (#3828). +- 3c1f809: Preserve `/* istanbul ignore … */` and `/* c8 ignore … */` block comments written as JSX children on the generated component `children` getter. Line comments are not carried. +- 98b916d: Fix compiled SSR output that renders `style=""` or `class=""` for `null` and `undefined`. Babel and the native compiler now omit these attributes on elements without a spread. +- 98d35b9: Fix computed keys in compiled SSR `style` objects (builds without `serverComponents`). A computed key's name got no `;`, so `style={{ color: "red", [k]: v }}` rendered `color:redtop:1px` and the browser dropped both declarations. Hydration keeps the server's inline style, so they stayed dropped. A nullish first value also no longer leaves a leading `;`. Both compilers now pass a multi-entry object to a new `ssrStyleProperties(name, value, …)` helper, which writes the separator only between the entries it writes; a single entry keeps `ssrStyleProperty`. +- 4f67697: **Breaking:** only `on` followed by an uppercase letter (`onClick`, `onPointerDown`) is an event handler. Lowercase `on*` names (`onclick`, `onmouseover`) are plain attributes everywhere: + - Both compilers compile `onclick={expr}` like any other attribute (`setAttribute`, reactive when `expr` is dynamic) instead of binding a delegated or native event, and SSR renders it as an escaped attribute instead of dropping it. A leftover 1.x `on:click={fn}` is likewise a plain namespaced attribute (it previously compiled to `addEventListener(":click", fn)`). + - `@solidjs/web` `spread`/`assign` set lowercase `on*` keys as attributes, the server spread walk renders them, and `useHead` applies lowercase `on*` attributes (camelCase handler names stay skipped). `ssrAttribute` escapes a function value instead of interpolating its source raw. + - `@solidjs/html` and `@solidjs/h` elements wrap a function passed to a lowercase `on*` in a getter like any other attribute; only `onXxx` and `ref` are exempt. + - `@solidjs/html` components follow `@solidjs/h`'s rule: every zero-argument function prop, `onXxx` handlers and `ref` included, is a getter, so a component handler must declare its event argument (`onClick=${e => …}`). + - New dev-only check `LOWERCASE_EVENT_ATTRIBUTE` (added to the `DiagnosticCode` union): warns once per attribute name when a function is set on a lowercase `on*` (or `on:`) attribute, naming the camelCase handler to use. + +- 7513131: Preserve the source location of captured references in SSR props constructors so source maps point to the authored expression, including dynamic TSRX tags. + ## 2.0.0-rc.13 ## 2.0.0-rc.12 diff --git a/packages/babel-plugin/package.json b/packages/babel-plugin/package.json index 779917d3d..e474d1fa8 100644 --- a/packages/babel-plugin/package.json +++ b/packages/babel-plugin/package.json @@ -1,7 +1,7 @@ { "name": "@solidjs/babel-plugin", "description": "Babel compiler plugin for Solid templates", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "author": "Ryan Carniato", "license": "MIT", "repository": { diff --git a/packages/compiler/CHANGELOG.md b/packages/compiler/CHANGELOG.md index f7e2f9518..5b7285c9e 100644 --- a/packages/compiler/CHANGELOG.md +++ b/packages/compiler/CHANGELOG.md @@ -1,5 +1,27 @@ # @solidjs/compiler +## 2.0.0-rc.14 + +### Patch Changes + +- ba8c593: Restore Clippy and rustfmt checks for the native compiler and apply the resulting lint and formatting cleanups +- 3c1f809: Preserve `/* istanbul ignore … */` and `/* c8 ignore … */` block comments written as JSX children on the generated component `children` getter. Line comments are not carried. +- 5dbe29a: Count all JavaScript line terminators in scoped style and refresh locations and DOM and server-function diagnostics. Report diagnostic columns in UTF-16 units. +- a8c98bd: Preserve the source location of captured references in SSR props constructors so source maps point to the authored expression instead of the start of the JSX element, matching `@solidjs/babel-plugin`. +- 59fb244: SSR `hoistProps` no longer captures names in TypeScript type positions (type parameters, annotations, `as`/`satisfies` targets, type arguments, `typeof x` queries, local `type`/`interface` declarations, `implements`/`extends` heritage) as constructor arguments, which threw `ReferenceError` once the types were stripped (#3828). A `type` or `interface` that shares a value's name no longer makes that value count as redeclared, so its site still hoists. +- ab57910: Report correct TSRX diagnostic positions after Unicode line separators and carriage returns, preserving UTF-16 columns and treating CRLF as one line break. +- 41be120: The `@solidjs/compiler-wasm32-wasi` fallback loads on Android (Termux), where the filesystem root cannot be opened: its generated loader no longer preopens `/` there (it failed with `UVWASI_EACCES, uvwasi_init`). The loader is regenerated by `@napi-rs/cli` 3.10.6, which maps the WASI root to the working directory on Android. +- c8aac88: Fix native TSRX compilation of parenthesized keys, iterables, and conditions, including annotated `@for` loops used directly in a component body. Map comments back to the authored source to prevent invalid JavaScript and Unicode panics when source maps are enabled. +- 98b916d: Fix compiled SSR output that renders `style=""` or `class=""` for `null` and `undefined`. Babel and the native compiler now omit these attributes on elements without a spread. +- 98d35b9: Fix computed keys in compiled SSR `style` objects (builds without `serverComponents`). A computed key's name got no `;`, so `style={{ color: "red", [k]: v }}` rendered `color:redtop:1px` and the browser dropped both declarations. Hydration keeps the server's inline style, so they stayed dropped. A nullish first value also no longer leaves a leading `;`. Both compilers now pass a multi-entry object to a new `ssrStyleProperties(name, value, …)` helper, which writes the separator only between the entries it writes; a single entry keeps `ssrStyleProperty`. +- ea5f1da: Fix native TSRX compilation when a setup statement has no semicolon before markup. +- 4f67697: **Breaking:** only `on` followed by an uppercase letter (`onClick`, `onPointerDown`) is an event handler. Lowercase `on*` names (`onclick`, `onmouseover`) are plain attributes everywhere: + - Both compilers compile `onclick={expr}` like any other attribute (`setAttribute`, reactive when `expr` is dynamic) instead of binding a delegated or native event, and SSR renders it as an escaped attribute instead of dropping it. A leftover 1.x `on:click={fn}` is likewise a plain namespaced attribute (it previously compiled to `addEventListener(":click", fn)`). + - `@solidjs/web` `spread`/`assign` set lowercase `on*` keys as attributes, the server spread walk renders them, and `useHead` applies lowercase `on*` attributes (camelCase handler names stay skipped). `ssrAttribute` escapes a function value instead of interpolating its source raw. + - `@solidjs/html` and `@solidjs/h` elements wrap a function passed to a lowercase `on*` in a getter like any other attribute; only `onXxx` and `ref` are exempt. + - `@solidjs/html` components follow `@solidjs/h`'s rule: every zero-argument function prop, `onXxx` handlers and `ref` included, is a getter, so a component handler must declare its event argument (`onClick=${e => …}`). + - New dev-only check `LOWERCASE_EVENT_ATTRIBUTE` (added to the `DiagnosticCode` union): warns once per attribute name when a function is set on a lowercase `on*` (or `on:`) attribute, naming the camelCase handler to use. + ## 2.0.0-rc.13 ## 2.0.0-rc.12 diff --git a/packages/compiler/npm/darwin-arm64/package.json b/packages/compiler/npm/darwin-arm64/package.json index 315b88ceb..7c6e56153 100644 --- a/packages/compiler/npm/darwin-arm64/package.json +++ b/packages/compiler/npm/darwin-arm64/package.json @@ -1,6 +1,6 @@ { "name": "@solidjs/compiler-darwin-arm64", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "cpu": [ "arm64" ], @@ -19,4 +19,4 @@ "os": [ "darwin" ] -} \ No newline at end of file +} diff --git a/packages/compiler/npm/darwin-x64/package.json b/packages/compiler/npm/darwin-x64/package.json index 761629a22..d5d08d134 100644 --- a/packages/compiler/npm/darwin-x64/package.json +++ b/packages/compiler/npm/darwin-x64/package.json @@ -1,6 +1,6 @@ { "name": "@solidjs/compiler-darwin-x64", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "cpu": [ "x64" ], @@ -19,4 +19,4 @@ "os": [ "darwin" ] -} \ No newline at end of file +} diff --git a/packages/compiler/npm/linux-arm64-gnu/package.json b/packages/compiler/npm/linux-arm64-gnu/package.json index b3b8ced9d..92d43bdc0 100644 --- a/packages/compiler/npm/linux-arm64-gnu/package.json +++ b/packages/compiler/npm/linux-arm64-gnu/package.json @@ -1,6 +1,6 @@ { "name": "@solidjs/compiler-linux-arm64-gnu", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "cpu": [ "arm64" ], @@ -22,4 +22,4 @@ "libc": [ "glibc" ] -} \ No newline at end of file +} diff --git a/packages/compiler/npm/linux-x64-gnu/package.json b/packages/compiler/npm/linux-x64-gnu/package.json index 262baa254..c8fbcaa6b 100644 --- a/packages/compiler/npm/linux-x64-gnu/package.json +++ b/packages/compiler/npm/linux-x64-gnu/package.json @@ -1,6 +1,6 @@ { "name": "@solidjs/compiler-linux-x64-gnu", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "cpu": [ "x64" ], @@ -22,4 +22,4 @@ "libc": [ "glibc" ] -} \ No newline at end of file +} diff --git a/packages/compiler/npm/wasm32-wasi/package.json b/packages/compiler/npm/wasm32-wasi/package.json index 5bbbf6b3c..717f691bc 100644 --- a/packages/compiler/npm/wasm32-wasi/package.json +++ b/packages/compiler/npm/wasm32-wasi/package.json @@ -1,6 +1,6 @@ { "name": "@solidjs/compiler-wasm32-wasi", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "main": "compiler.wasi.cjs", "files": [ "compiler.wasm32-wasi.wasm", @@ -26,4 +26,4 @@ "@emnapi/core": "1.11.3", "@emnapi/runtime": "1.11.3" } -} \ No newline at end of file +} diff --git a/packages/compiler/npm/win32-x64-msvc/package.json b/packages/compiler/npm/win32-x64-msvc/package.json index a4de0ee94..8e6b97c6c 100644 --- a/packages/compiler/npm/win32-x64-msvc/package.json +++ b/packages/compiler/npm/win32-x64-msvc/package.json @@ -1,6 +1,6 @@ { "name": "@solidjs/compiler-win32-x64-msvc", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "cpu": [ "x64" ], @@ -19,4 +19,4 @@ "os": [ "win32" ] -} \ No newline at end of file +} diff --git a/packages/compiler/package.json b/packages/compiler/package.json index b84923f19..917ed2b1a 100644 --- a/packages/compiler/package.json +++ b/packages/compiler/package.json @@ -1,7 +1,7 @@ { "name": "@solidjs/compiler", "description": "Solid's native Oxc JSX compiler", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "author": "Ryan Carniato", "license": "MIT", "repository": { @@ -62,11 +62,11 @@ "emnapi": "^1.11.3" }, "optionalDependencies": { - "@solidjs/compiler-darwin-x64": "2.0.0-rc.13", - "@solidjs/compiler-darwin-arm64": "2.0.0-rc.13", - "@solidjs/compiler-linux-x64-gnu": "2.0.0-rc.13", - "@solidjs/compiler-linux-arm64-gnu": "2.0.0-rc.13", - "@solidjs/compiler-win32-x64-msvc": "2.0.0-rc.13", - "@solidjs/compiler-wasm32-wasi": "2.0.0-rc.13" + "@solidjs/compiler-darwin-x64": "2.0.0-rc.14", + "@solidjs/compiler-darwin-arm64": "2.0.0-rc.14", + "@solidjs/compiler-linux-x64-gnu": "2.0.0-rc.14", + "@solidjs/compiler-linux-arm64-gnu": "2.0.0-rc.14", + "@solidjs/compiler-win32-x64-msvc": "2.0.0-rc.14", + "@solidjs/compiler-wasm32-wasi": "2.0.0-rc.14" } } diff --git a/packages/diagnostics/CHANGELOG.md b/packages/diagnostics/CHANGELOG.md index 37ebea4ea..f5197c66e 100644 --- a/packages/diagnostics/CHANGELOG.md +++ b/packages/diagnostics/CHANGELOG.md @@ -1,5 +1,127 @@ # @solidjs/diagnostics +## 2.0.0-rc.14 + +### Patch Changes + +- Updated dependencies [4b4c2cb] +- Updated dependencies [0c550fd] +- Updated dependencies [ecb68a1] +- Updated dependencies [d4b10b5] +- Updated dependencies [b07fed5] +- Updated dependencies [2eb6e00] +- Updated dependencies [21ff8f8] +- Updated dependencies [3c1d512] +- Updated dependencies [1b9ceb6] +- Updated dependencies [fa371c3] +- Updated dependencies [96c5e19] +- Updated dependencies [9a213bb] +- Updated dependencies [721eb06] +- Updated dependencies [721eb06] +- Updated dependencies [b0c6e6a] +- Updated dependencies [365f37d] +- Updated dependencies [b07fed5] +- Updated dependencies [bc51ada] +- Updated dependencies [eaddda4] +- Updated dependencies [da84bd9] +- Updated dependencies [d231b99] +- Updated dependencies [98d35b9] +- Updated dependencies [3086f1b] +- Updated dependencies [b57eb2e] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [9d89df7] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [3c1d512] +- Updated dependencies [1b9ceb6] +- Updated dependencies [203ab1a] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [3c7631a] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [09eadfe] +- Updated dependencies [e44b2e4] +- Updated dependencies [01e80a6] +- Updated dependencies [be82cf3] +- Updated dependencies [759a9b6] +- Updated dependencies [fd9f381] +- Updated dependencies [b07fed5] +- Updated dependencies [fff1615] +- Updated dependencies [11e9fb6] +- Updated dependencies [11e9fb6] +- Updated dependencies [b0bad02] +- Updated dependencies [0c550fd] +- Updated dependencies [2317623] +- Updated dependencies [e345dc7] +- Updated dependencies [4f67697] +- Updated dependencies [2317623] +- Updated dependencies [d1309ad] +- Updated dependencies [924d909] +- Updated dependencies [6be6c51] +- Updated dependencies [41fdf96] +- Updated dependencies [7acc039] +- Updated dependencies [87a3862] +- Updated dependencies [bde4299] +- Updated dependencies [53ef0e6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [1b9ceb6] +- Updated dependencies [2656284] +- Updated dependencies [9338c00] +- Updated dependencies [7addcc6] +- Updated dependencies [6f77b1b] +- Updated dependencies [537e945] +- Updated dependencies [1a3f87f] +- Updated dependencies [5622be8] +- Updated dependencies [11e9fb6] +- Updated dependencies [b07fed5] +- Updated dependencies [b0bad02] +- Updated dependencies [b07fed5] +- Updated dependencies [b0c8489] +- Updated dependencies [7233451] +- Updated dependencies [8d66ae5] + - solid-js@2.0.0-rc.14 + - @solidjs/signals@2.0.0-rc.14 + - @solidjs/web@2.0.0-rc.14 + ## 2.0.0-rc.13 ### Patch Changes diff --git a/packages/diagnostics/package.json b/packages/diagnostics/package.json index 2d90d79c1..472017b88 100644 --- a/packages/diagnostics/package.json +++ b/packages/diagnostics/package.json @@ -1,6 +1,6 @@ { "name": "@solidjs/diagnostics", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "description": "Agent-consumable diagnostics harness for Solid: capture the dev-mode diagnostic and attribution channels as structured artifacts, with assertion helpers for tests and agent loops.", "author": "Ryan Carniato", "license": "MIT", @@ -52,11 +52,11 @@ "test:watch": "vitest watch tests" }, "dependencies": { - "@solidjs/signals": "^2.0.0-rc.13" + "@solidjs/signals": "^2.0.0-rc.14" }, "peerDependencies": { - "@solidjs/web": "^2.0.0-rc.13", - "solid-js": "^2.0.0-rc.13", + "@solidjs/web": "^2.0.0-rc.14", + "solid-js": "^2.0.0-rc.14", "vitest": ">=2.0.0" }, "peerDependenciesMeta": { diff --git a/packages/element/CHANGELOG.md b/packages/element/CHANGELOG.md index 4b4baf41b..594c728e5 100644 --- a/packages/element/CHANGELOG.md +++ b/packages/element/CHANGELOG.md @@ -1,5 +1,70 @@ # solid-element +## 2.0.0-rc.14 + +### Patch Changes + +- Updated dependencies [4b4c2cb] +- Updated dependencies [ecb68a1] +- Updated dependencies [d4b10b5] +- Updated dependencies [2eb6e00] +- Updated dependencies [21ff8f8] +- Updated dependencies [3c1d512] +- Updated dependencies [9a213bb] +- Updated dependencies [721eb06] +- Updated dependencies [b0c6e6a] +- Updated dependencies [365f37d] +- Updated dependencies [da84bd9] +- Updated dependencies [98d35b9] +- Updated dependencies [b57eb2e] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [9d89df7] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [3c1d512] +- Updated dependencies [1b9ceb6] +- Updated dependencies [203ab1a] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [3c7631a] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [e44b2e4] +- Updated dependencies [01e80a6] +- Updated dependencies [be82cf3] +- Updated dependencies [759a9b6] +- Updated dependencies [e345dc7] +- Updated dependencies [4f67697] +- Updated dependencies [41fdf96] +- Updated dependencies [87a3862] +- Updated dependencies [53ef0e6] +- Updated dependencies [2656284] +- Updated dependencies [9338c00] +- Updated dependencies [7addcc6] +- Updated dependencies [6f77b1b] +- Updated dependencies [537e945] +- Updated dependencies [7233451] +- Updated dependencies [8d66ae5] + - solid-js@2.0.0-rc.14 + - @solidjs/web@2.0.0-rc.14 + ## 2.0.0-rc.13 ### Patch Changes diff --git a/packages/element/package.json b/packages/element/package.json index d79f7ff53..b29db52e6 100644 --- a/packages/element/package.json +++ b/packages/element/package.json @@ -3,7 +3,7 @@ "description": "Webcomponents wrapper for Solid", "author": "Ryan Carniato", "license": "MIT", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "homepage": "https://github.com/solidjs/solid/blob/main/packages/element#readme", "repository": { "type": "git", @@ -30,8 +30,8 @@ "component-register": "^0.8.7" }, "peerDependencies": { - "solid-js": "^2.0.0-rc.13", - "@solidjs/web": "^2.0.0-rc.13" + "solid-js": "^2.0.0-rc.14", + "@solidjs/web": "^2.0.0-rc.14" }, "devDependencies": { "solid-js": "workspace:*", diff --git a/packages/h/CHANGELOG.md b/packages/h/CHANGELOG.md index 3b644fa59..f17a18c8a 100644 --- a/packages/h/CHANGELOG.md +++ b/packages/h/CHANGELOG.md @@ -1,5 +1,72 @@ # @solidjs/h +## 2.0.0-rc.14 + +### Patch Changes + +- ecb68a1: Binding slots: the fill runs once per occurrence, untracked, under the occurrence's owner — as a component body and a template-slot fill do. State created in the fill lives as long as the occurrence; a top-level read is a one-time read (dev: `STRICT_READ_UNTRACKED`, naming the fill); getters are the reactive form. Handlers and refs are read once when an element binds and go through `assign`, so events delegate, tuples bind and interactions wrap as in client JSX. On the server an array at a handler position is a dev finding (reason `tuple`) instead of being flattened; only `ref` merges arrays. Template-slot fills are untracked on every render path and carry the same labelled warning. + + Breaking: `AttributeSlot` is renamed `BindingSlot`, with no alias, and its return is constrained (`SlotOutput` / `SlotError`, both exported) so an array, DOM node, function, async value or `$`-prefixed key is a type error on both sides. The diagnostic code `ATTRIBUTE_SLOT_POSITION` is renamed `BINDING_SLOT_POSITION`. The fill-shape finding also names async values. + +- 9e85a09: `h()` no longer writes to the caller's props object, so an element can be materialized again (a `Show` re-showing children whose own children are `h()` elements threw "Cannot set property children … which has only a getter"). An `h()` element returned from an accessor child is now created in the insert's tracking pass rather than re-created whenever its output changes (an accessor returning `h(Loading, …)` over async children never settled). A function `class` on a tag with static classes (`h("span.a", { class: () => … })`) keeps the static classes. `h(...)` with element/component arguments is typed as `HyperElement`, so `render(h(App), el)` — the documented root form, now corrected in the README — type-checks. +- 4f67697: **Breaking:** only `on` followed by an uppercase letter (`onClick`, `onPointerDown`) is an event handler. Lowercase `on*` names (`onclick`, `onmouseover`) are plain attributes everywhere: + - Both compilers compile `onclick={expr}` like any other attribute (`setAttribute`, reactive when `expr` is dynamic) instead of binding a delegated or native event, and SSR renders it as an escaped attribute instead of dropping it. A leftover 1.x `on:click={fn}` is likewise a plain namespaced attribute (it previously compiled to `addEventListener(":click", fn)`). + - `@solidjs/web` `spread`/`assign` set lowercase `on*` keys as attributes, the server spread walk renders them, and `useHead` applies lowercase `on*` attributes (camelCase handler names stay skipped). `ssrAttribute` escapes a function value instead of interpolating its source raw. + - `@solidjs/html` and `@solidjs/h` elements wrap a function passed to a lowercase `on*` in a getter like any other attribute; only `onXxx` and `ref` are exempt. + - `@solidjs/html` components follow `@solidjs/h`'s rule: every zero-argument function prop, `onXxx` handlers and `ref` included, is a getter, so a component handler must declare its event argument (`onClick=${e => …}`). + - New dev-only check `LOWERCASE_EVENT_ATTRIBUTE` (added to the `DiagnosticCode` union): warns once per attribute name when a function is set on a lowercase `on*` (or `on:`) attribute, naming the camelCase handler to use. + +- Updated dependencies [ecb68a1] +- Updated dependencies [d4b10b5] +- Updated dependencies [2eb6e00] +- Updated dependencies [721eb06] +- Updated dependencies [365f37d] +- Updated dependencies [98d35b9] +- Updated dependencies [b57eb2e] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [3c1d512] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [9d89df7] +- Updated dependencies [9d89df7] +- Updated dependencies [7233451] +- Updated dependencies [3c1d512] +- Updated dependencies [1b9ceb6] +- Updated dependencies [203ab1a] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [3c7631a] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [7233451] +- Updated dependencies [e44b2e4] +- Updated dependencies [01e80a6] +- Updated dependencies [be82cf3] +- Updated dependencies [4f67697] +- Updated dependencies [41fdf96] +- Updated dependencies [53ef0e6] +- Updated dependencies [2656284] +- Updated dependencies [9338c00] +- Updated dependencies [7addcc6] +- Updated dependencies [6f77b1b] +- Updated dependencies [537e945] +- Updated dependencies [7233451] +- Updated dependencies [8d66ae5] + - @solidjs/web@2.0.0-rc.14 + ## 2.0.0-rc.13 ### Patch Changes diff --git a/packages/h/package.json b/packages/h/package.json index b253d3999..2bddf4480 100644 --- a/packages/h/package.json +++ b/packages/h/package.json @@ -1,7 +1,7 @@ { "name": "@solidjs/h", "description": "Hyperscript / h() factory for Solid — write components without compiled JSX.", - "version": "2.0.0-rc.13", + "version": "2.0.0-rc.14", "author": "Ryan Carniato", "license": "MIT", "homepage": "https://solidjs.com", @@ -58,7 +58,7 @@ "test": "vitest run" }, "peerDependencies": { - "@solidjs/web": "^2.0.0-rc.13" + "@solidjs/web": "^2.0.0-rc.14" }, "devDependencies": { "@solidjs/web": "workspace:*", diff --git a/packages/html/CHANGELOG.md b/packages/html/CHANGELOG.md index c54434c72..17346b84c 100644 --- a/packages/html/CHANGELOG.md +++ b/packages/html/CHANGELOG.md @@ -1,5 +1,69 @@ # @solidjs/html +## 2.0.0-rc.14 + +### Patch Changes + +- a5d0e76: Zero-argument functions passed to component props named `on`, `only`, `once`, etc. are now wrapped in getters like any other dynamic prop (#3728). The `on*` exemption on components now covers only `onXxx` handler names (an uppercase letter after `on`), so `<${Loading} on=${() => key()}>` re-keys the boundary when `key()` changes. Native elements are unchanged: every `on*` prop is still passed through as an event handler. A lowercase `onclick` passed to a component is now wrapped in a getter; name it `onClick` or give the handler a parameter. +- 6be8486: Fix the tokenizer staying in raw text mode after a self-closing raw text element such as `