Huakun

Uniview

Infrastructure for building universal React plugin ecosystems with multi-framework hosts and isolated runtimes

Infrastructure for building universal React plugin ecosystems. Multi-framework hosts, isolated runtimes, type-safe RPC.

GitHub: https://github.com/HuakunShen/uniview
Documentation: https://huakunshen.github.io/uniview/

Overview

Uniview enables writing plugins in React or Solid that can be rendered by Svelte, Vue, React, or any other framework. Plugins run in isolated environments (Web Workers, Node.js, Deno, Bun) and communicate with hosts via RPC.

                              RPC (kkrpc)
┌───────────────────────┐ ◄──────────────────► ┌──────────────────┐
│  Plugin (React/Solid) │      UINode tree     │  Host (Svelte)   │
│  Web Worker           │                      │  or Vue, React   │
└───────────────────────┘                      └──────────────────┘

Key Features

  • Write plugins in React or Solid, render anywhere
  • Sandboxed execution in Web Workers for security
  • Server-side plugins via Node.js/Deno/Bun with WebSocket Bridge
  • Incremental updates - Only changed nodes are sent over RPC
  • Framework-agnostic protocol - hosts implement their own adapters
  • Type-safe RPC communication via kkrpc

Packages

PackageDescription
@uniview/protocolCore types, UINode schema, RPC interfaces
@uniview/react-rendererCustom React reconciler producing UINode trees
@uniview/solid-rendererSolid universal renderer producing UINode trees
@uniview/react-runtimeReact plugin bootstrap for Worker/WebSocket
@uniview/solid-runtimeSolid plugin bootstrap for Worker/WebSocket
@uniview/host-sdkFramework-agnostic host controller
@uniview/host-svelteSvelte 5 rendering adapter
@uniview/tui-rendererTerminal UI renderer (non-DOM)

Host Targets

Uniview plugins render on any target that implements the UINode protocol:

TargetRendering Approach
Svelte (Web)Svelte 5 ComponentRenderer
React (Web)React component tree
Vue (Web)Vue component tree
SwiftUI (macOS)Declarative SwiftUI views
AppKit (macOS)Imperative NSViews with diff reconciler
TerminalANSI escape codes

Runtime Modes

ModeEnvironmentIsolationUse Case
WorkerBrowserFull sandboxProduction, untrusted plugins
WebSocketNode.js/Deno/BunProcess boundaryServer-side, full runtime access
Main ThreadBrowserNoneDevelopment only

Built for Kunkun extension system.

On this page