Domain-Driven State Management

A state management library for TypeScript and ReScript supporting Domain-Driven Design.

Code should reflect your domain.
✨ Tilia is here to help ✨

const sky = tilia({
  color: 'pink' 🌈
})

observe(() => {
  console.log(sky.color)
})

function elevateVibes() {
  sky.color = 'legendary'}

// React integration

function Sky() {
  useTilia()

  return <div>{sky.color}</div>
}
let vibing = tilia({
  vibes: "immaculate" 🌈
})

@react.component
let make = () => {
  useTilia()

  <div>{React.string(vibing.vibes)}</div>
}

let elevateVibes = () => vibing.vibes = "legendary"

Why Developers Are Obsessed (or not)

🌱
No Boilerplate

The API is tiny and was made to be nearly invisible in your code.

🚀
Lightning Fast

A library written for data-intensive and highly interactive apps.

🌈
Type Safe

Tilia does not add tons of crazy types to your code. From seed to unicorn, you are in charge.

Main Features

Zero dependencies
Optimized for stability and speed
Highly granular reactivity
Combines pull and push reactivity
Tracking follows moved or copied objects
Compatible with ReScript and TypeScript
Optimized computations (no recalculation, batch processing)
Tiny footprint (8KB) ✨