nexum

Compile-time reactive web framework for Nim with SSR & Islands

Pure Nim score 15/100 · tests present · no docs generated

Summary

Latest Version 0.1.0
License AGPL-3.0
CI Status Failing
Downloads 0
Last Indexed 2026-09-05 07:26

Authors

  • Nexum Contributors

Installation

nimble install nexum
choosenim install nexum
git clone https://github.com/nim-community/nexum

OS Compatibility

Platform Linux macOS Windows FreeBSD OpenBSD NetBSD Android iOS WASM Embedded
nexum - - - - - - -

Dependencies

Package Version Optional
nim >= 2.2.0 No

Source

Repository https://github.com/nim-community/nexum
Homepage https://github.com/nim-community/nexum
Registry Source nimble_official

README

Nexum

A compile-time reactive web framework for Nim.
Zero virtual DOM. Full SSR. Partial hydration.

Nexum is a next-generation frontend framework that leverages Nim's macro system to do at compile time what other frameworks do at runtime. It generates fine-grained DOM updates from reactive signals, produces server-rendered HTML with island hydration markers, and ships minimal JavaScript to the browser.

Philosophy

  • Compile-time reactivity: buildHtml is a macro. It analyzes your templates, finds dynamic parts, and generates Signal subscriptions that call concrete DOM setters. No VDOM tree, no diff.
  • Isomorphic by default: The same component code compiles to both a C server binary (emitting HTML strings) and a JS client bundle (mounting/hydrating DOM).
  • Islands architecture: Static pages ship zero JS. Only components marked {.island.} are hydrated on the client.

Quick Start (Vision)

import nexum

# A reactive component
{.island.}
component Counter:
  var count = signal(0)

  buildHtml:
    button(onclick = () => count += 1):
      text "Clicked "
      text count
      text " times"

# Server entry
proc main() =
  let app = initApp()
  # renderToString integrates with your HTTP server
  echo renderPage(app, Counter())

# Client entry
proc start() =
  let app = initApp()
  startClient(app)

Architecture

See ARCHITECTURE.md for the full design document, including: - Signal-based fine-grained reactivity - Compile-time client/server code generation - Hydration without VDOM diff - Streaming SSR roadmap

Status

Experimental / Design phase.
Core signal runtime and project skeleton are in place. The buildHtml macro compiler and full hydration engine are under active design.

License

GNU Affero General Public License v3.0 (AGPL-3.0)