Minor Changes
-
BREAKING CHANGE: mixin render callbacks no longer receive
childrenorinnerHTML, and returned mixin elements cannot override host subtree content.handle.elementandcreateElement(handle.element, ...)are now limited to patching host props and nestedmixvalues. -
Add an
attrs(...)mixin for applying default host props throughmix. Recipe authors can now provide attributes such astype="button"without overriding explicit JSX props, which makes it easier to build reusable element recipes that include both styling and safe defaults. -
Allow nested arrays in
mixprops and flatten them during JSX normalization. This makes it easier to compose reusable style and behavior recipes without manually spreading arrays before passing them to elements or components. -
renderToStream()now accepts aresolveClientEntry(entryId, component)callback for resolving opaque client entry IDs during server rendering.For example:
import type { RemixNode } from 'remix/component' import { renderToStream } from 'remix/component/server' import { resolveEntryId } from './resolve-entry-id.ts' export function render(node: RemixNode) { return renderToStream(node, { async resolveClientEntry(entryId, component) { return { href: await resolveEntryId(entryId), exportName: entryId.split('#')[1] || component.name, } }, }) }
Patch Changes
-
Fix controlled
<select>restore timing sochangehandlers can read and commit the newly selected value.When a browser dispatches
inputbeforechangefor a select interaction, Remix Component now defers controlled restoration for selects to thechangephase instead of restoring oninput, which prevents stale controlled values from clobbering the pending selection before app handlers run. -
handle.signalin mixins now aborts when that specific mixin slot is removed, even if the host node stays mounted. This fixes cleanup patterns that expecthandle.signalto match the mixinremovelifecycle.