Reference

Targets

What each of the eight targets writes, the capability matrix of where frameworks differ, how each target takes events, and how Angular hosts a component.

Unframework compiles each component to eight targets. Each one writes a component in its framework's own format, and imports nothing but its framework. solid@2 is opt-in: a project selects it in targets, and the default is the other seven (Configuration).

TargetFileComponent
ReactProductTile.tsxA function component
VueProductTile.vueA single-file component with <script setup lang="ts">
SvelteProductTile.svelteA component in runes mode, with <script lang="ts">
Angularproduct-tile.tsA component class with signal inputs and an inline template
SolidProductTile.tsxA function component
Solid 2ProductTile.tsxA function component, for Solid 2 (solid@2)
QwikProductTile.tsxA component$
AstroProductTile.astroA component with its props in the frontmatter

Props shows the files for one component.

Capabilities

A capability is a feature a component can use: a kind of node, a kind of attribute, or something a framework does at run time. Each target declares, for every capability, how it supports it:

  • native: the framework has the feature, and the output uses it;
  • emulated: the output adds a small inline helper, named in the cell, because the framework lacks the feature;
  • unsupported: the framework renders the feature differently, or not at all. The compiler reports UF4001 at the feature's first use, with the target's reason, and the cell sets its severity; sheet-order reports its own code, UF4002, Angular's child-root-scope UF4003, Angular's generic-slot-props UF4004, and React's, Solid's and Solid 2's composable-effect-order UF4005.

So a difference between frameworks is declared here, never found only in a test.

CapabilityWhat it coversReactVueSvelteAngularSolidSolid 2QwikAstro
elementHTML elementsnativenativenativenativenativenativenativenative
textStatic textnativenativenativenativenativenativenativenative
static-attributeAttributes with a literal valuenativenativenativenativenativenativenativenative
listboxA <select> shown as a single-selection list boxnativeunsupportednativenativenativenativenativenative
interactivityListeners, template refs, watchers and hooksnativenativenativenativeemulated createWatcheremulated createWatchernativeunsupported
event-captureA listener in the capture phase, onClickCapturenativenativenativeemulated uf<Event>Capturenativenativenativeunsupported
event-onceA listener that runs once, onClickOnceemulated useOncenativeemulated onceemulated uf<Event>Oncenativenativeemulated once<Event>unsupported
event-passiveA passive listener, onWheelPassivenativenativenativeemulated uf<Event>Passivenativenativenativeunsupported
event-semanticsA listener hears the DOM's event of its nameemulated listennativenativenativenativenativenativeunsupported
conditional-event-controlAn event control that runs on more than the eventnativenativenativenativenativenativeunsupportedunsupported
use-iduseId(): ids unique on the pagenativenativenativeemulated idCounternativenativenativeemulated uniqueId
next-ticknextTick(): waiting for the DOM to updateemulated useNextTicknativenativeemulated nextTickemulated nextTickemulated nextTickemulated nextTickunsupported
late-propA prop the parent passes only after the mountnativenativenativenativenativenativeunsupportednative
propsA component with propsnativenativenativenativenativenativenativenative
interpolationExpressions rendered as textnativenativenativenativenativenativenativenative
conditionalc ? <A /> : <B /> and c && <A />nativenativenativenativenativenativenativenative
list.map with a key: the items' content and ordernativenativenativenativenativenativenativenative
fragmentA root fragment with several nodesnativenativenativenativenativenativenativenative
bound-attributeAttributes bound to an expressionnativenativenativenativenativeemulated enumeratedValuenativenative
class-bindingA class of names, toggles and expressionsemulated cxnativenativeemulated classNamesemulated cxemulated cxnativenative
style-bindingA style of static and bound declarations, or bound to a valueemulated styleObjectnativeemulated styleTextemulated styleObjectemulated stylePropertiesemulated stylePropertiesemulated styleObjectemulated styleObject
attribute-spreadA spread of an object whose type declares its keysnativenativenativenativenativeemulated enumeratedValuenativenative
raw-htmlinnerHTML={markup}: markup set as an element's contentnativenativenativeemulated TrustedHtmlPipenativenativenativenative
svgAn <svg> and the SVG inside itnativenativenativenativenativenativenativenative
componentA component element, <Field />nativenativenativenativenativenativenativenative
component-eventA listener of a child's event, onClearnativenativenativenativenativenativenativeunsupported
default-slotThe default slot: children, {slots.default?.()}nativenativenativenativenativenativenativenative
named-slotA named slot without propsnativenativenativeemulated uf<Component><Slot>nativenativeemulated <slot>$native
scoped-slotA slot with props, {slots.item?.({ item })}nativenativenativeemulated uf<Component><Slot>nativenativeemulated <slot>$emulated <slot>
slot-fallbackA slot's fallback content, after ??nativenativenativenativenativenativenativenative
default-slot-presenceslots.default as a condition, or forwardednativenativenativeunsupportednativenativeunsupportednative
slot-forwardingA parent's slot passed on, {{ title: slots.title }}nativenativenativeemulated uf<Component><Slot>nativenativenativenative
modeldefineModel, and v-model:name on a componentnativenativenativenativenativenativenativenative
two-way-bindingv-model on a form controlnativenativenativenativenativenativenativeunsupported
model-arrayv-model of a checkbox group or a multiple selectemulated togglenativenativeemulated toggleemulated toggleemulated toggleemulated toggleunsupported
model-modifiersv-model_trim, _lazy, _number, a number inputemulated modelTextnativeemulated modelTextemulated modelTextemulated modelTextemulated modelTextemulated modelTextunsupported
fallthroughA class or style on a componentnativenativeemulated mergeStyleemulated fallthroughnativenativenativenative
contextual-rootA root element tied to its parent: <li>, <tr>, …nativenativenativeunsupportednativenativenativenative
exposedefineExpose, and a ref on a componentnativenativenativenativenativenativeemulated exposeRefunsupported
contextprovide and inject with an injection keynativenativenativenativenativenativenativeunsupported
reactive-contextA provided ref or computed valueemulated refObjectnativeemulated refObjectemulated refObjectemulated refObjectemulated refObjectnativeunsupported
dynamic-component<component is> over a known setnativenativenativeemulated @switchnativenativenativenative
teleport<Teleport to>: one element mounted into to once the component has mountedemulated teleportnativeemulated teleportemulated Teleportemulated Teleportemulated Teleportemulated teleportunsupported
transition<Transition>: Vue's enter and leave classes on one element or a conditional'semulated Transitionnativeemulated enteremulated Transitionemulated Transitionemulated Transitionemulated transitionunsupported
directivev-name={value}: a directive's hooks run on its element, in the browseremulated useDirectivenativenativeemulated runDirectiveemulated queueHookemulated queueHookemulated runDirectiveunsupported
scoped-stylesA sibling stylesheet the compiler scopesnativenativenativenativenativenativenativenative
child-root-scopeA child's root taking a styled parent's scopeemulated scopeAttributesnativeemulated scopeAttributesunsupportedemulated scopeAttributesemulated scopeAttributesemulated scopeAttributesemulated scopeAttributes
slotted-stylesSlot content a :slotted() rule stylesnativenativenativenativenativenativenativenative
sheet-orderThe order sheets cascade in: Vue's import ordernativenativenativeunsupportednativenativeunsupportednative
generic-componentsA component with type parameters, function List<T>nativenativenativenativenativenativenativenative
generic-slot-propsA scoped slot whose props name a type parameternativenativenativeunsupportednativenativenativenative
composablesA call of a composable from a .uf.ts modulenativenativenativenativenativenativenativenative
composable-effect-orderA composable's effects in the caller's orderunsupportednativenativenativeunsupportedunsupportednativeunsupported
hydrationA server render that hydrates into the client's DOM, with its ids, and stays interactivenativenativenativenativenativenativeunsupportedunsupported
keyed-identityA keyed item keeps its element while its list reorders or replaces itnativenativenativenativeemulated KeyedForemulated KeyedFornativeunsupported
async-setupAn async setup: the server renders what it awaited, and a hydrated page keeps the server's DOM while it runs againemulated SetupPendingnativenativenativenativenativenativenative

The cells that are not native:

  • React, class-binding: React's className takes one string, so an inline helper, cx, joins the static names, toggles and dynamic parts. Where a part may be an array or an object at run time, cx reads an array's entries too, as Vue's normalizeClass does.
  • React, style-binding: React's style takes an object, so a style bound to a value goes through an inline helper, styleObject, which splits a declaration list into an object as Vue's parseStringStyle does, with camel-case keys. An object passes as it is. Declarations print as an object.
  • React, event-once: React has no once listener, so a guard, useOnce, remembers each element the listener ran for, as { once: true } removes a listener from its own element only.
  • React, event-semantics: where React's synthetic event differs from the DOM's (change on a text field, a checkbox or a radio, select, beforeinput, a wheel or touch listener that is not passive, the events React has no prop for, and focus or blur beside a native focusin or focusout), the element's ref callback, declared once, listens natively, through listen.
  • React, next-tick: React has no nextTick, so a hook, useNextTick, asks for a render at the priority of the code that calls it, and resolves once React has rendered it, run its effects and rendered what the component's watchers wrote. After a click's or a key's handler it resolves in the event's task, as on Vue; after a watcher's write, in an effect, in a timer or after an await, in a later task (Semantics). It resolves when the component unmounts too.
  • React, model-array: React's checkbox takes one boolean, so a checkbox group's array goes through an inline helper, toggle, which adds or removes the box's value, as Vue's vModelCheckbox does.
  • React, model-modifiers: React has no v-model modifiers, so an inline helper, modelText, a hook named useModelText in the output, trims and casts as Vue's vModelText does, and writes a lazy field as it loses focus.
  • React, child-root-scope: a child cannot know the scope attributes its styled parents pass it, data-uf-<id>, since each name is a parent's id, so an inline helper, scopeAttributes, picks the data-uf-* keys out of the rest of its props and spreads them on its root, on each branch of a root conditional and on a root <component is> too, as Vue's fallthrough reaches them. No other undeclared prop reaches the root.
  • React, reactive-context: a context passes its value once per render of the provider, so a provided ref is an object with a value getter, refObject, made again at each render. Descendants render each change, and code that runs later, after an await or in a timer, reads the value of their last render.
  • React, composable-effect-order (for information): a composable is a custom hook, and React runs a component's effects in its own order, so a composable's watchers, effects and hooks cannot take their place among the caller's own, and code that relies on that order may see another. The compiler reports UF4005 at the composable's call.
  • React, directive: React has no directive, so an element's directive goes through an inline hook, useDirective, called once per use at the component's top level. Its ref callback records each element it receives, so a callback written in place keeps the directive and each element one use renders gets its own hooks, and its layout effect runs mounted, updated when the value changes and unmounted. A directive whose value reads a list's row or a scoped fill's props calls useElementDirective instead, whose function makes each element's ref callback from its value as the row renders, withTrace(item.label), joined with the element's other callbacks through an inline mergeRefs. The hooks go through an inline queue, queueHook, which runs them in Vue's order once the turn ends (ADR-0099, ADR-0108).
  • React, transition: React has no transition primitive, so an inline component, Transition, renders the child, whose branches each take a key. A change of key keeps the old element, as it last rendered, beside the new one until its leave ends. It owns the classes in state, since React writes the whole class attribute when className changes, keeps the child's own ref, and renders no class on the server or while the client hydrates (ADR-0100).
  • React, async-setup: a component can't await in React, so a function of the module, profileSetup for Profile, runs the awaits, and the component starts it once and renders an inner one, ProfileResolved, which reads the result with use inside a <Suspense>. Its fallback, an inline component, SetupPending, renders nothing and tells the component once the setup settles, so React shows the content at once rather than after its fallback throttle. A prop update that arrives while the component hydrates and its setup is pending makes React render it on the client: the server's DOM goes, and nothing shows until the setup resolves, with no mismatch reported. Under StrictMode in development the setup runs twice (ADR-0101).
  • Svelte, event-once: a once listener's handler goes through an inline wrapper, once, whose guard is set when the handler first runs, never the DOM's { once: true }: Svelte's on runs the handlers it delegated below the element inside its own listener, so the option would be used up by an event one of them stopped.
  • Svelte, style-binding: Svelte's style takes a declaration list, so a style bound to a value goes through an inline helper, styleText, which writes an object's present values as declarations, in kebab case, as Vue's stringifyStyle does. A string passes as it is. Declarations print as style: directives.
  • Svelte, fallthrough: a component's style prop is a string, which cannot unset a property, so an inline helper, mergeStyle, merges the consumer's declarations over the root's own and drops the root's declaration of a property the consumer's style sets to a nullish value, as an object merge does.
  • Svelte, child-root-scope: a child cannot know the scope attributes its styled parents pass it, data-uf-<id>, since each name is a parent's id, so an inline helper, scopeAttributes, picks the data-uf-* keys out of its $props() and spreads them on its root, on each branch of a root conditional and on a root <component is> too, as Vue's fallthrough reaches them. A parent passes them in an object spread, {...{ "data-uf-<id>": "" }}, since svelte-check rejects a prop the child does not declare.
  • Svelte, model-modifiers: bind:value has no modifiers, so an inline helper, modelText, trims, casts and waits for change as Vue's vModelText does.
  • Svelte, reactive-context: setContext passes a value once, so a provided ref is an object with a value getter, refObject, which descendants read as it changes.
  • Svelte, teleport: Svelte has no portal, so the element renders once the component has mounted, in an {#if} of its own, and an attachment, teleport, moves it into to, gives back the focus the move takes, and removes it on teardown. Svelte still delegates its events, since mount() listens on document too (ADR-0098).
  • Svelte, transition: Svelte's transitions run their own CSS or ticks, never Vue's classes, so each element of the conditional takes a local in:enter and out:leave, whose functions run the classes in a config Svelte calls for every run, and give Svelte the element's duration. A run stops what the element's other phase still runs, as when Svelte reverses a leave. Svelte ends both elements of a swap by that duration, and the classes go then, at introend and outroend. With appear, in: is global, so the enter runs as the element first mounts too (ADR-0100).
  • Solid, class-binding: Solid's class takes one string, so an inline helper, cx, joins dynamic parts with the static names and toggles. Static names and toggles alone print as class and classList. Where a part may be an array or an object at run time, cx reads an array's entries too, as Vue's normalizeClass does.
  • Solid, style-binding: Solid's style takes an object with kebab-case keys, so a style bound to a value goes through an inline helper, styleProperties, which writes an object's camel-case keys in kebab case and splits a declaration list as Vue's parseStringStyle does. Declarations print as an object.
  • Solid, child-root-scope: a child cannot know the scope attributes its styled parents pass it, data-uf-<id>, since each name is a parent's id, so an inline helper, scopeAttributes, picks the data-uf-* keys out of its props by name and spreads them on its root, on each branch of a root conditional and on a root <component is> too, as Vue's fallthrough reaches them. It reads no prop's value, so it runs no getter.
  • Solid, interactivity: state, derived values, listeners and hooks are Solid's own. Solid runs what a write triggers as the write is made, so a watcher goes through an inline helper, createWatcher, and a watchEffect through createWatchEffect, over a scheduler: createReaction queues a watcher when a value it read is written, and a microtask runs each queued watcher once, those before the DOM updates first, with Vue's previous value, change test and cleanup timing. Client code is copied as written, with no batch: the watchers, not the writes, keep the contract's timing.
  • Solid, next-tick: Solid applies writes to the DOM as it makes them, and the watchers run in a microtask queued at the first write, so an inline nextTick resolves a promise.
  • Solid, model-array, model-modifiers and reactive-context: Solid has no v-model, so inline helpers bind a checkbox group's array (toggle), a multiple select's (selectedValues), the options of a select that a component, a slot or an interpolation renders (selectOptions) and a text field's modifiers (modelText), as Vue does; a provided ref is an object with a value getter, refObject, which descendants read as it changes.
  • Solid, keyed-identity: Solid's <For> follows the items themselves, so an item replaced by a copy of the same key would get a new element, and lose its focus and typed text. So a list goes through an inline helper over <For>, KeyedFor, whose rows follow the source's key, as Vue's do. A row is an object of getters named as the item, item.value and item.index, which TypeScript narrows as it narrows a prop, and follows the latest item of its key.
  • Solid, composable-effect-order (for information): a composable's watchers coalesce in its own module's queue, createWatcher, apart from the caller's, so its watchers, effects and hooks cannot take their place among the caller's own, and code that relies on that order may see another. The compiler reports UF4005 at the composable's call.
  • Solid, teleport: Solid's <Portal> wraps its content in a <div>, so an inline helper, Teleport, inserts the element into to once the component has mounted, as <Portal> does in <head>, in a root its owner owns, so the element reads the component's context (ADR-0098).
  • Solid, transition: Solid's own transitions are a package, which no output imports, so an inline component, Transition, resolves the child and keeps a leaving element among the nodes it renders until its leave ends. The server renders the child as it is (ADR-0100).
  • Solid, directive: a directive is a ref factory, ref={vFocusTrap(() => open())}, Solid 2's own form. Solid runs an element's ref before its children's, so the hooks go through an inline queue, queueHook, which runs them in Vue's order once the turn ends (ADR-0099).
  • Solid 2, interactivity: Solid 2 lets a read see a write only once it flushes, on a microtask or at flush(), which an effect's callback or onSettled cannot call, and Vue's read sees a write at once. So state goes through an inline helper, createState, a signal whose read returns the value last written and tracks the signal where something observes it; a derived value is a function, () => count() * 2, which reads the latest values too. Solid applies what a write changes when it flushes, as Vue renders after a tick. A watcher goes through createWatcher, and a watchEffect through createWatchEffect, over a scheduler queued at the write, which applies Solid's writes and runs each queued watcher once, those before the DOM updates first, with Vue's previous value, change test and cleanup timing. Hooks run from onSettled, and a template ref is emptied with its element through clearedRef, which registers the cleanup as the ref is evaluated, since Solid 2 refuses onCleanup in a ref callback.
  • Solid 2, next-tick: Solid 2 applies writes on a microtask queued at the first write, which queues the watchers' run, so an inline nextTick resolves two microtasks on.
  • Solid 2, bound-attribute and attribute-spread: Solid 2 writes a boolean as an attribute's presence, where Vue writes the boolean of an ARIA attribute and of contenteditable, draggable and spellcheck as its name, aria-expanded="false". So such a value, bound or from a spread's key, goes through an inline helper, enumeratedValue, that writes "true" or "false" and passes any other value as it is.
  • Solid 2, class-binding: static names and toggles print as Solid 2's own class array, class={["tab", { active: active() }]}, which replaces classList. A dynamic part, or the class of a spread, goes through cx, which joins them into one string, as a component's class prop takes it.
  • Solid 2, style-binding, child-root-scope, model-array, model-modifiers and reactive-context: as on Solid. modelText and selectOptions are factories that return the element's ref callback, since Solid 2 creates no computation inside one.
  • Solid 2, keyed-identity: as on Solid, a list goes through KeyedFor, whose rows follow the source's key.
  • Solid 2, composable-effect-order (for information): as on Solid, a composable's watchers coalesce in its own module's queue. The compiler reports UF4005 at the composable's call.
  • Solid 2, teleport: Solid 2's <Portal> inserts its content with no wrapper, but it throws on the server and renders where it is created, so an inline helper, Teleport, renders a <Portal> into to once the component has mounted, the teleports in the order they rendered (ADR-0098).
  • Solid 2, transition: as on Solid, an inline component, Transition, keeps a leaving element until its leave ends. It resolves the child on the server too, so the child takes the same hydration keys on both sides (ADR-0100).
  • Solid 2, directive: as on Solid, a ref factory whose hooks go through queueHook. Its mounted hook runs from onSettled, its updated from an effect whose compute reads the value, and Solid 2's server runs the factory too, where its primitives do nothing (ADR-0099).
  • Angular, event-capture, event-once and event-passive: a template's (event) binding takes no listener options, so the file declares an attribute directive for each event and option, [ufClickCapture], which listens with Renderer2.listen and emits the event again. A once listener beside another listener of its event on its element runs with it in one template listener, in attribute order, under a guard instead, once(clickOnce, $event) && …: a method that remembers the elements it ran for.
  • Angular, use-id: Angular has no id API, so a counter, idCounter, makes each instance's ids, uf-id-<component>-<n>, as Angular Material makes its own. It is one per application, so a server render and the browser that hydrates it count the same ids.
  • Angular, class-binding: [class] reads no nested array and drops an entry that holds a space, so a class part that may be an array or an object at run time goes through an inline helper, classNames, which reads it as Vue's normalizeClass does. Every other class is Angular's own class and [class].
  • Angular, style-binding: a style bound to a value is Angular's own [style], but where an object spread merges it, on the root beside the consumer's style and on a component or a <component is>, whose root spreads it, an inline helper, styleObject, first splits a declaration list into an object as Vue's parseStringStyle does.
  • Angular, raw-html: Angular sanitises a bound innerHTML, which drops id, data-* and style attributes, form controls and SVG, so the markup goes through an inline pure pipe, TrustedHtmlPipe, which marks it trusted with DomSanitizer.bypassSecurityTrustHtml, and renders as written.
  • Angular, next-tick: Angular renders a change in a later task, so a private nextTick method renders the pending change itself in a microtask, ApplicationRef.tick(), as Vue does, and resolves after it.
  • Angular, named-slot, scoped-slot and slot-forwarding: each named slot is a directive the component's file exports, ng-template[uf<Component><Slot>], which the component reads with contentChild and renders with ngTemplateOutlet under @if; a scoped one types the consumer's let- variables with ngTemplateContextGuard, and a forwarded one re-declares the child's template with the parent's as its content.
  • Angular, model-array, model-modifiers and reactive-context: a native control's v-model is a property binding and a listener, so inline helpers bind a checkbox group's array (toggle), a multiple select's (selectedValues) and a text field's modifiers (modelText); a provided ref is an object with a value getter, refObject.
  • Angular, fallthrough: a component that inherits class and style declares them as inputs, merges them into its root element and clears them from its host, which keeps only display: contents.
  • Angular, dynamic-component: a strict template cannot choose a component by value, so an @switch renders each candidate.
  • Angular, default-slot-presence (an error): Angular has no API for whether <ng-content> received content, and forwarding the default slot would re-project <ng-content />, which always counts as content.
  • Angular, child-root-scope (for information): a child cannot know the scope attributes its styled parents write on its host, data-uf-<id>, since each name is a parent's id, and the host must keep only display: contents. So each root node binds an inline attribute directive to the host, [ufScope]="this.host", which takes the host's data-uf-* attributes off it as the node renders and sets them on the node: on each branch of a root conditional and each candidate of a root <component is> too, as Vue's fallthrough reaches them. A root component passes them on to its own root. But the root renders inside its host element, which selectors see: a parent's rule that reaches the root through a combinator (>, +, ~) or a structural pseudo-class (:first-child, :nth-child(), …) matches the host's place, not the root's, and may match differently. And a root Angular binds nothing on ({{ in an attribute) takes no scope attribute. The compiler reports UF4003 at the first child a styled component renders.
  • Angular, sheet-order (for information): Angular adds a component's sheet to the page as the component first renders: a parent's before its children's, and siblings in the order they render, where the other targets load them in import order, a child's first. Where two sheets' rules of equal specificity meet on one element (a child's root, content filled into a slot, :deep(), :global()), the winner can differ. The compiler reports UF4002 at a component's first stylesheet import, and a test whose captures depend on the winner requires sheet-order.
  • Angular, contextual-root (an error): a root element HTML or ARIA ties to its parent (li, dt, dd, tr, td, th, thead, tbody, tfoot, caption, colgroup, col, option, optgroup, summary, legend) renders inside the host element, which breaks the parent's content model: axe reports list and listitem, and the HTML parser moves a host out of a table. Keep the <li> in the parent and render its content in the component.
  • Angular, generic-slot-props (for information): Angular infers a component's type parameter from its inputs alone, and a slot's directive cannot infer it, so a scoped slot's context takes the parameter's constraint, where the other targets type the consumer's fill by the type argument. The component renders the same. The compiler reports UF4004 at the slot, or at a consumer's fill of it.
  • Angular, teleport: the CDK's portals are no framework import, so the element is an <ng-template> whose inline directive, Teleport, creates its view after a render that leaves the template's anchor in the document, attaches it to the application, moves its nodes into to, and refreshes it after every render. The view is in no view container, so a slot's projection never moves its nodes, and a template projected into a slot that isn't rendered waits for it. A render's teleports mount in the document's order, and a component whose whole render is a teleport takes its parents' scope attributes off its host (ADR-0098).
  • Angular, transition: animate.enter and animate.leave take one class list, which can't run Vue's three phases, so the element takes an inline directive, Transition. A conditional child sits in an <ng-container> whose inline directive, TransitionRegion, is created with the transition and holds the branch shown. The element's directive runs the enter once its region has rendered, or with appear, so an element a condition around the transition shows again enters only with appear. One element of a transition without a conditional enters only with appear. It runs the leave through (animate.leave)'s function form, which holds the element's removal until the leave ends. Angular runs that function too when something around the element removes it, so the directive lets the element go at once while its region still shows its branch (ADR-0100).
  • Angular, directive: a directive is a standalone attribute directive, [vFocusTrap], whose afterRenderEffect passes its value to an inline helper, runDirective. Angular creates projected content before a child puts it in the document, and keeps it while the child takes it out, so the helper runs mounted and unmounted as a MutationObserver sees the element come and go. Angular mounts a parent before its child in one view and a child in an @if before its parent, so the hooks go through an inline queue, queueHook, which runs them in Vue's order (ADR-0099).
  • Qwik, event-once: Qwik's listeners have no once, so a module-level set of the elements a once listener ran for, once<Event>, is checked first in its handler, which also takes the element's preventdefault: and stoppropagation: attributes off after its first run, unless another listener of the element still needs them.
  • Qwik, style-binding: a style bound to a value is Qwik's own style, but where an object spread merges it, on the root beside the consumer's style and on a component or a <component is>, whose root spreads it, an inline helper, styleObject, first splits a declaration list into an object as Vue's parseStringStyle does.
  • Qwik, next-tick: Qwik has no public way to wait for a render, so nextTick resolves after the next task, by which time the render its writes scheduled, in a microtask, has run.
  • Qwik, conditional-event-control (an error): Qwik runs a handler once its code has loaded, after the event is dispatched, so it runs preventDefault() and stopPropagation() apart, while the event is dispatched. A control at the top of a template listener runs on every event, as the element's preventdefault:click; one there under a test of the event alone, or after guard clauses on the event, runs in a sync$ handler, which captures nothing. Qwik cannot run any other control at dispatch: one after another statement, in a block beside other statements, in an else or a switch case, after a test of state or of what a control changes (event.defaultPrevented), or in a function the listener calls anywhere but at its top. Nor can it run a once listener's control under a condition or on an element that listens to the event in both phases (a sync$ handler cannot tell whether the listener already ran), a capture listener's control where an element of the component listens to the event in both phases (Qwik runs those capture listeners from the window), or a control in a local function that reads the component's state and that client code hands to addEventListener or calls outside a template listener. Make the control the first statement of the listener, or the only statement under an if that tests only the event, and keep a once listener's control unconditional; in a listener that client code adds, make the control in the listener itself, before it calls a local function. The keyboard handler of a list box, a switch on event.key with a control in each case, has no Qwik output (Events).
  • Qwik, late-prop (a warning): Qwik subscribes a useComputed$ or a task only to the props the component holds when it reads them. A derived value or a watcher that reads an optional prop the parent did not pass at mount, and passes later (a spread that gains the key), does not see it, though the template does. Pass the prop from the start, undefined while it has no value.
  • Qwik, named-slot and scoped-slot: Qwik's <Slot> takes no props and has no presence API, and a plain function prop does not serialise, so a named slot is a QRL render prop, <slot>$.
  • Qwik, model-array and model-modifiers: Qwik has no v-model, so inline helpers bind a checkbox group's array (toggle), a multiple select's (selectedValues) and a text field's modifiers (modelText), as Vue does.
  • Qwik, expose: Qwik has no component instance, so a component ref is a signal the child fills with what it exposes, through an inline helper, exposeRef.
  • Qwik, default-slot-presence (an error): Qwik's <Slot /> has no presence API, and forwarding the default slot needs it.
  • Qwik, child-root-scope: a child cannot know the scope attributes its styled parents pass it, data-uf-<id>, since each name is a parent's id, so an inline helper, scopeAttributes, picks the data-uf-* keys out of the rest of its props and spreads them on its root, on each branch of a root conditional and on each candidate of a root <component is> too, as Vue's fallthrough reaches them.
  • Qwik, sheet-order (for information): useStyles$ adds a component's sheet to the page as the component first renders: a parent's before its children's, and siblings in the order they render, where the other targets load them in import order, a child's first. Where two sheets' rules of equal specificity meet on one element (a child's root, content filled into a slot, :deep(), :global()), the winner can differ. Qwik's server render also writes the sheet as a <style> element before the component's root, which :first-child, :nth-child() and + count in the server's markup. The compiler reports UF4002 at a component's first stylesheet import, and a test whose captures depend on the winner requires sheet-order.
  • Qwik, hydration (for information): Qwik resumes a server render instead of hydrating it. It runs no render, keeps no state for a component without client code, and runs visible tasks once the loader sees them, so the tests can't check a resumed page against a client render yet. A server render still resumes, unchecked.
  • Qwik, teleport: Qwik has no portal, so the element renders once a visible task says the component has mounted, after an empty text in a fragment, which Qwik inserts a sibling before in its place. A ref, teleport, moves the element into to, puts it back there when Qwik moves it with its component, makes it stand in for its Qwik container there, so its handlers still find it, and removes it once the element that held it leaves the document (ADR-0098).
  • Qwik, transition: Qwik removes a node at once and has no transition primitive, so a signal lists the branches the transition renders, starting at the condition's value. A visible task that tracks the branch shown runs the old element's leave, drops it at the leave's end unless it is shown again first, which stops the leave, and adds the new one, whose ref, transition, runs its enter as Qwik creates it. An element a condition around the transition shows again enters only with appear, since a branch's mark goes if no element took it within two frames (ADR-0100).
  • Qwik, directive: Qwik has no directive, so an element's directive is a ref function that adds each element one use renders to a signal of them, and a visible task that tracks them and the value, and calls an inline helper, runDirective, for each. A directive whose value reads a list's row or a scoped fill's props takes it from the element: its ref is collectValues, which lists the element with the values it reads as the row renders, and the task runs each element with its own. A MutationObserver sees an element come into the document, where a slot may put it after Qwik calls the ref, and leave it, since a conditional's removal runs no task, and an inline queue runs the hooks in Vue's order (ADR-0099, ADR-0108).
  • Vue, listbox (an error): Vue's client sets multiple but not size before it inserts the options, so it selects the first option, as a drop-down does, where HTML selects none.
  • Astro, interactivity (for information): Astro components render on the server only, and each render is a new instance: event handlers, template refs, watchers and lifecycle hooks never run, and state keeps its initial value. A test that relies on client code is skipped on Astro, and the parity matrix shows the skip with this reason.
  • Astro, event-capture, event-once, event-passive, event-semantics, conditional-event-control and next-tick (for information): they refine interactivity, so the compiler reports interactivity alone, once, at the first listener, ref, watcher or hook.
  • Astro, use-id: a counter on Astro.locals, uniqueId, which lives for one request, makes ids unique on the page and the same for every request.
  • Astro, style-binding: a style bound to a value is Astro's own style, but where an object spread merges it, on the root beside the consumer's style and on a component or a <component is>, whose root spreads it, an inline helper, styleObject, first splits a declaration list into an object as Vue's parseStringStyle does.
  • Astro, component-event, two-way-binding, model-array, model-modifiers, expose and composable-effect-order (for information): they refine interactivity, so the compiler reports interactivity alone. A child's listener never runs, a v-model renders its initial state, nothing calls what a component exposes, and a composable's watchers, effects and hooks never run.
  • Astro, scoped-slot: Astro loses a slot's arguments behind the <Fragment slot> its compiler writes, so a scoped slot is a render prop named as the slot, <slot>.
  • Astro, child-root-scope: a child cannot know the scope attributes its styled parents pass it, data-uf-<id>, since each name is a parent's id, so an inline helper, scopeAttributes, picks the data-uf-* keys out of Astro.props and spreads them on its root, on each branch of a root conditional and on a root <component is> too, as Vue's fallthrough reaches them.
  • Astro, context and reactive-context (warnings): Astro renders each component on its own, with no tree of instances to provide to, so inject gives its fallback, and a provided ref reaches no descendant.
  • Astro, hydration (for information): Astro components render on the server only, with no client runtime, so nothing hydrates.
  • Astro, keyed-identity (for information): Astro renders a list once on the server, so nothing reorders it in the page. No list reports it: a test that reorders or replaces a list's items requires keyed-identity, and is skipped on Astro.
  • Astro, teleport (for information): a static page has no client to mount the content once the component has mounted, and printing it in place would put it in the server HTML, so the output prints nothing for it. A test that reads teleported content requires teleport, and is skipped on Astro.
  • Astro, transition (for information): a static page runs no transition, so the child prints as it would without one, settled, with no class. A test that sees a transition requires transition, and is skipped on Astro.
  • Astro, directive (for information): a static page runs no hook, so the element renders without its directive. A test that reads what a hook does requires directive, and is skipped on Astro.

A native cell takes no note, so these are declared here (ADR-0060):

  • React, two-way-binding (native): a checkbox's or a radio's v-model is controlled checked with React's onChange, which React fires on the DOM's click, before input, so a listener of the control's input reads the model the click wrote, where Vue's reads the value from before the click (Semantics). react-dom also writes a box's or an option's first state as its checked or selected attribute and never updates it; the live state still compares, so the parity tests leave that attribute out on React. A <textarea>'s v-model puts the caret after the text once the field is mounted, as Vue's set value does, since react-dom fills the field as its default value, which leaves the caret at the start. The one exception is a <textarea> with a native listener that reads a list's row or a narrowed value: its ref callback runs at every render, so it leaves the caret at the start.
  • React, teleport: React 19's server render throws on a portal, so the element is createPortal from react-dom, through an inline helper, teleport, once useSyncExternalStore says the component has mounted: false on the server and while the client hydrates. The helper renders nothing where to matches no element. A React package peers on react-dom for it (ADR-0098).
  • Vue, async-setup (native): Vue renders an async setup only under a <Suspense>, so a .uf.tsx parent wraps each use of an async child in one, and a hand-written Vue parent must do the same. A component whose whole render is an async child turns inheritAttrs off and binds $attrs on the child, since <Suspense> drops fallthrough (ADR-0101).
  • Svelte, async-setup (native): Svelte awaits in the instance script only in its async mode, so the host sets compilerOptions.experimental.async, which Svelte labels experimental, for each file whose instance script awaits or for the whole app. Svelte's async runtime is then on for the whole page. Template refs, mounted hooks and a provide of props, module values and globals move above the awaits, since Svelte allows them only while a component starts. A provide that reads an awaited value or a later item can't move, so the compiler reports it as UF1002 (ADR-0101).
  • Solid, async-setup (native): a resource runs the awaits, and the rest of the setup renders inside a <Show> once it resolves. After hydration Solid creates that subtree again once the setup resolves: the new nodes read the same, but focus and selection inside them reset. With the data Solid's server render ships by default, the client hydrates in place and doesn't run the setup again, which the tests don't cover, since their server render leaves that data out (ADR-0101).
  • Solid 2, async-setup (native): an async createMemo runs the awaits, and the rest of the setup renders inside a keyed <Show> under <Loading> once it resolves. Solid 2 hydrates that subtree in place only with the values its server render serializes, so after hydration the awaits don't run again on the client, and the rest of the setup does. The contract allows either: a component depends neither on its setup running once nor twice (ADR-0102).

Every other difference between the frameworks is either handled by the target that has it, or rejected for every target by the compiler, with a code that names the framework. Attributes, Templates and Events list them, and Semantics states what every target guarantees at run time, and the differences that the compiler cannot see (Outside the contract).

Component events

A component declares its events with defineEmits (Events), and each target takes them in its framework's convention, keeping the event's name, apart from Angular's prefix for the names of DOM events:

TargetA parent listens to change withThe listener receives
Reactthe prop onChangethe payload's members, as arguments
Vue@changethe payload's members, as arguments
Sveltethe prop onchangethe payload's members, as arguments
Angularthe output (ufChange)nothing for an empty payload, the value for one required member, and a tuple for any other payload
Solidthe prop onChangethe payload's members, as arguments
Qwikthe prop onChange$the payload's members, as arguments; the listener may run after the emit
Astronothingnothing: Astro components render on the server only, and emit nothing

Angular's output() emits one value, so a payload of two members or more, or with an optional member, is a tuple of exactly the arguments the emit gives: share: [path: string, note?: string] emits ["a.txt"] or ["a.txt", "Please review"]. React, Solid and Qwik type their event props with an exported interface beside the props, <Name>Events, and Svelte joins them to its Props type. Angular declares an output for each event under the event's name. An event named like a DOM event, such as change, select or progress, takes the uf prefix, ufChange, because an Angular output also hears the DOM's event of its name when that bubbles out of the host element: angular-eslint's no-output-native rule lists the names. Where a setup binding has that name, the class renames its own member: a local function save that emits save becomes the method onSave, and a state status the signal currentStatus.

The Angular host

Angular renders every component inside a host element, which wraps the template's root. The other frameworks render the root directly. Unframework gives each Angular component an element selector, uf- and its name in kebab case, and styles its host display: contents:

product-tile.ts
@Component({
  selector: "uf-product-tile",
  host: { "[attr.class]": "null", "[attr.style]": "'display: contents;'" },
  preserveWhitespaces: false,

A consumer writes <uf-product-tile>, Angular's ordinary element syntax. display: contents keeps the host out of layout, so the component's geometry and pixels match the other targets'. Its accessibility tree differs in one place: Playwright's ARIA snapshot puts a space at every element whose display isn't inline, the host included, so inline content on either side of a host reads "Build passing" where the other targets read "Buildpassing". The parity tests take Angular's snapshot with its hosts set to display: inline, so they add no space (ADR-0060). The template holds the whole render tree: a single root, the roots of a root fragment, and the conditionals and lists beside them all render inside the one host.

The host keeps nothing a consumer writes on it: [attr.class] and [attr.style] clear any class and style there, apart from its own display: contents. A consumer's class and style reach the component's root element through two inputs instead (Fallthrough), and a static prop is bound, [label]="'Name'", so that no attribute stays on the host.

Attribute selectors, which would make the consumer's own element the host, are left to a decision of their own, outside M3. Until they land, a component whose root must sit directly inside its parent, such as an <li> in a consumer's list or a <tr> in a consumer's table, cannot be written for Angular (contextual-root, an error): keep that element in the parent, and render the component inside it (Child components).

The decisions behind this page are ADR-0010, ADR-0012, ADR-0015, ADR-0033, ADR-0047, ADR-0055, ADR-0056 and ADR-0060.

Copyright © 2026