import{_ as i,o as a,c as t,ae as n}from"./chunks/framework.C8AWLET_.js";const g=JSON.parse('{"title":"Getting Started","description":"","frontmatter":{},"headers":[],"relativePath":"guide/getting-started.md","filePath":"guide/getting-started.md"}'),e={name:"guide/getting-started.md"};function l(h,s,p,k,r,d){return a(),t("div",null,[...s[0]||(s[0]=[n(`
SigPro is a lightweight, atomic reactive engine designed to build modern web interfaces with zero overhead. It focuses on high performance through fine-grained reactivity.
You can install SigPro via your favorite package manager:
npm install SigPropnpm add SigProyarn add SigProbun add SigProThe core of SigPro is the $ function, which creates reactive state (Signals) and computed effects.
Create a main.js file and try this:
import { $ } from 'SigPro';
// 1. Create a reactive signal
const $name = $("World");
// 2. Define a reactive component
const App = () => div({ class: 'container' }, [
h1(["Hello, ", $name, "!"]),
input({
type: 'text',
$value: $name, // Two-way binding
placeholder: 'Enter your name...'
}),
button({
onclick: () => $name("SigPro")
}, "Set to SigPro")
]);
// 3. Mount the application
$.mount(App, '#app');SigPro doesn't use a Virtual DOM. Instead, it creates real DOM nodes and binds them directly to your data:
$(value) creates a getter/setter function.By default, SigPro exports common HTML tags to the global scope (window) when initialized. This allows you to write clean, declarative UI without importing every single tag:
// Instead of $.html('div', ...), just use:
div([
h1("Clean Syntax"),
p("No more boilerplate.")
]);