diff --git a/changelog/core/0.7.63.md b/changelog/core/0.7.63.md new file mode 100644 index 000000000..71b8331a4 --- /dev/null +++ b/changelog/core/0.7.63.md @@ -0,0 +1,17 @@ +--- +package: "@webjsdev/core" +version: 0.7.63 +date: 2026-10-07T11:35:08.909Z +commit_count: 1 +--- +## Breaking + +- **omit a null or undefined attribute hole in SSR, matching the client** ([#1574](https://github.com/webjsdev/webjs/pull/1574)) [`2a9613cf`](https://github.com/webjsdev/webjs/commit/2a9613cf) + A plain attribute hole (`attr=${value}`) now follows one rule on the server + and the client. `null` and `undefined` omit the attribute, so + `aria-current=${active ? 'page' : null}` no longer serves `aria-current=""`. + `false` omits it too, except on an `aria-*` attribute, where both renderers + write `"false"`. Markup changes: the server no longer emits `attr=""` or a + non-aria `attr="false"`, and the client now writes `aria-x="false"` instead + of removing it. A bound form's `method=${null}` is no longer refused; the + framework supplies `method="post"`. Quoted and mixed holes are unchanged. diff --git a/package-lock.json b/package-lock.json index 23311987d..818098ce7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -6996,7 +6996,7 @@ }, "packages/core": { "name": "@webjsdev/core", - "version": "0.7.62", + "version": "0.7.63", "license": "MIT", "devDependencies": { "esbuild": "^0.25.0" diff --git a/packages/core/package.json b/packages/core/package.json index c8243c126..28dbd4613 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@webjsdev/core", - "version": "0.7.62", + "version": "0.7.63", "type": "module", "description": "The runtime for WebJs, a full-stack JavaScript framework built on web components with server-side rendering and no build step. Ships the html and css template tags, the WebComponent base class, signals, directives, and the isomorphic renderers.", "types": "./index.d.ts",