Skip to content

Releases: countradooku/gpui-native

GPUI Native v0.2.0

Choose a tag to compare

@github-actions github-actions released this 11 Sep 16:56

GPUI Native 0.2.0

Distribution status: All six package archives and three native bindings are available below. npm publication is pending.

GPUI Native 0.2.0 brings Vue, React, and Svelte to the same native GPU-rendered
component engine, with clearer component names and shared WebGPU canvas support.
Frameworks own application state and reconciliation; GPUI owns layout, input,
text shaping, selection, focus, scrolling, painting, and windows.

Packages

All packages move together to 0.2.0:

Package Included functionality
@gpui-native/core Native N-API loader, declarations, and bindings for Apple Silicon macOS, Linux x64, and Windows x64
@gpui-native/runtime Framework-neutral host operations, batching, native props, events, automation, text search, and GPU resources
@gpui-native/vue Vue 3 renderer, typed components, composables, headless controls, testing, and native/browser entry points
@gpui-native/react React 19.2 reconciler, JSX components, hooks, headless controls, testing, and native/browser entry points
@gpui-native/svelte Svelte 5 runes adapter, compiler/Vite plugin, bindings, snippets, controls, testing, and native/browser entry points
gpui-vue Compatibility package containing the Vue adapter under its shorter name

The Rust gpui-core crate and example package versions are synchronized to 0.2.0.
The Rust crate is built into the native/WebAssembly artifacts; this release does
not publish it separately to crates.io. GitHub release assets include the three
native bindings and six installable npm package archives. The browser gallery
remains available at https://countradooku.github.io/gpui-native/.

React and Svelte support

  • React 19.2: a dedicated reconciler and typed JSX target, native refs and
    hooks, independent roots, headless Select/Combobox/Tooltip controls, and testing
    and automation support. The adapter does not load Vue or React DOM.
  • Svelte 5: real $state, $derived, $effect, $props, and $bindable
    support, two-way native input bindings, snippets, keyed lists, async branches,
    contexts, stores, lifecycle cleanup, window APIs, and GPU-canvas ownership.
  • The Svelte compiler and isolated client runtime are pinned together to
    Svelte 5.57.0. Use gpuiSvelte() to compile .svelte components and
    .svelte.ts/.svelte.js rune modules. The bridge does not replace browser globals.
  • Both adapters use the same retained-tree mutation protocol as Vue. Rust/core
    remain independent of every framework.

Clearer native components

All three adapters expose View, Text, Button, Row, Column, ScrollView,
TextInput, TextArea, Image, Svg, Canvas, Anchored, Code, Diff,
Markdown, VirtualList, and MotionView / motion.View.

View is a bare GPUI container. Layout helpers add useful flex/scroll defaults
that application styles can override. Button is unstyled, accepts arbitrary
content, and supports pointer/accessibility activation, Enter, and Space release.
Disabled buttons suppress activation, held keys do not repeatedly activate, and
blur cancels a pending Space press. Styling stays under application control.

Select, Combobox, Tooltip, floating layers, motion, window controls, text search,
virtualized lists, native editable text/IME, canvas drawing, and decoded audio
queues remain available through their framework APIs. Code stays a bare
primitive: applications own its background, padding, border, and header.

Shared wgpu engine and WebGPU canvas

  • Native WebGPU now uses a framework-neutral Rust wgpu engine and the project's
    Node-API bindings in Bun and Node. Dawn remains a development benchmark baseline.
  • Canvas sources share GPUI's renderer where supported, with explicit device
    ownership, bounded frame queues, pooled immutable GPU snapshots, and producer/
    compositor completion tracking.
  • Direct presentation performs a GPU snapshot copy, not a CPU readback or
    zero-copy transfer. GPUI composites the resulting texture alongside native UI.
  • Explicit asynchronous readback remains available where direct presentation
    is unsupported. Capability failures are reported rather than silently switching
    transports.
  • Lifecycle coverage includes resizing, source cleanup, async pipeline creation,
    resource destruction, canvas reuse, and multiple sources. Examples cover WGSL,
    compute, textures, MSAA, and Three.js.
  • Metal canvas repaints are scheduled on the main-thread host tick, and native
    Vue WebGPU example bundling is corrected.

Examples, browser gallery, and tooling

  • React counter, showcase, multiple-window, and WebGPU examples.
  • Svelte counter, showcase, multiple-window, and WebGPU examples, including native
    builds, standalone executable builds, and the WebAssembly gallery.
  • Existing Vue market-stream, chat, canvas, motion/timeline, multi-window, audio,
    counter, and WebGPU examples use the clearer component API.
  • Gallery navigation now derives supported routes from its buttons. React,
    Svelte, and WebGPU selections no longer fall back to the Vue counter; iframe
    destinations, selected state, URL hashes, and standalone links stay aligned.
  • Strict type/lint/format checks include the Svelte adapter and examples. Release
    automation packages and publishes all adapters together.
  • GPU-backed native tests exercise layout, clicks, keyboard input, accessibility,
    bound editors, dropdown placement, text-search navigation, and cleanup.

Performance and validation

The Svelte regression benchmark mounts 10,000 rows and performs 1,000 leaf
updates
. Each update produces exactly one text mutation in one native batch.
An adapter-only run measured approximately 0.076 ms median on the development
machine; that measurement excludes retained-backend processing, layout, and
painting and is not a frame-rate guarantee.

Local verification passed 101 JavaScript tests and 249 Rust tests, strict quality
checks, native build/smoke tests, the Pages build, and native/browser examples.
Browser checks covered bound inputs, rune updates, floating selection, multiple
windows, GPU scenes, and all 15 gallery destinations. Release automation gates
native artifacts on its quality and native test jobs across macOS, Linux, and
Windows. CI success is not a substitute for hardware qualification.

Migration and current limits

  • Legacy Vue/React Gpui* names and MotionDiv aliases remain supported. Svelte
    starts with the new component names.
  • Vue Text now means the native text component. If an application imported
    Vue's internal text VNode symbol from the adapter, import it directly from vue
    or @vue/runtime-core instead.
  • Native artifacts use the gpui-native prefix and the Rust crate is gpui-core.
    GPUI_NATIVE_LIBRARY_PATH is the preferred override; the older
    GPUI_VUE_NATIVE_LIBRARY_PATH remains a fallback.
  • Svelte is a native target. Browser DOM libraries, CSS stylesheets/directives,
    SSR, hydration, DOM actions, and browser transitions are not supported; use
    native styles, motion, and window APIs. Hot reload currently reloads the app.
  • Match-count callbacks aggregate ordinary text nodes. Rich-text primitives such
    as Markdown need an externally supplied match count for find navigation.
  • Windows direct GPU presentation is not implemented; use explicit readback.
    Linux physical-GPU/display qualification, Metal multi-GPU qualification, full
    WebGPU conformance, and long-duration soak testing remain outstanding. Native
    screenshot testing is supported on macOS and Windows, not Linux.
  • This is still an early 0.2.x release, not a claim of universal production or
    WebGPU conformance. See the platform matrix and guides before shipping.

Guides

Includes the framework work from #7, shared GPU presentation from #8, and Svelte,
component naming, and gallery fixes from #9, plus the native engine's upstream
synchronization and accessibility/input improvements.