> ## Documentation Index
> Fetch the complete documentation index at: https://sprincul.sinfullycoded.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Sprincul: Add Reactivity to HTML with JavaScript Classes

> Sprincul adds reactivity to your HTML using plain JavaScript classes and data attributes — no bundler, no template syntax, no virtual DOM.

Sprincul is a lightweight, browser-side JavaScript framework that enhances server-rendered HTML with reactive behavior. Instead of replacing your markup with a virtual DOM, Sprincul connects your existing HTML elements to JavaScript class instances through `data-*` attributes — keeping behavior close to your markup without sacrificing code organization.

<CardGroup cols={2}>
  <Card title="Quick Start" icon="rocket" href="/quickstart">
    Build your first reactive component in under five minutes.
  </Card>

  <Card title="Installation" icon="download" href="/installation">
    Install via npm, pnpm, bun, or import directly from a CDN.
  </Card>

  <Card title="Core Concepts" icon="book" href="/concepts/models">
    Understand models, data bindings, events, and lifecycle hooks.
  </Card>

  <Card title="API Reference" icon="code" href="/reference/sprincul-api">
    Full reference for the Sprincul class and SprinculModel base class.
  </Card>
</CardGroup>

## How it works

Sprincul revolves around three things: **models**, **bindings**, and **HTML attributes**. You write a plain JavaScript class, annotate your HTML, and Sprincul wires everything together at initialization.

<Steps>
  <Step title="Define a model">
    Create a class that extends `SprinculModel`. Initialize reactive state in `beforeInit()` and add methods that update the DOM or handle events.
  </Step>

  <Step title="Register and initialize">
    Register your model classes with `Sprincul.register()`, then call `Sprincul.init()` to scan the DOM and wire all bindings.
  </Step>

  <Step title="Annotate your HTML">
    Mark elements with `data-model`, `data-bind-*`, and native event attributes like `onclick`. Sprincul handles the rest.
  </Step>
</Steps>

## Why Sprincul?

<CardGroup cols={2}>
  <Card title="No framework syntax" icon="check">
    Behavior lives in your JavaScript classes, not inline expressions. No template language to learn.
  </Card>

  <Card title="No bundler required" icon="check">
    Import directly from a CDN via `<script type="module">` and get started immediately.
  </Card>

  <Card title="Works with server-rendered HTML" icon="check">
    Enhance existing markup without rewriting your templates or adopting a full SPA framework.
  </Card>

  <Card title="TypeScript ready" icon="check">
    First-class TypeScript support with typed state interfaces and exported types.
  </Card>
</CardGroup>
