Zero runtime dependencies
Ships nothing into your dependency tree. Runs in Node 22+, Bun, and the browser.
A constrained expression language for pricing rules, search filters, workflow conditions, and user-authored logic. Replace fragile eval()-style glue with typed errors, cacheable compilation, and real sandbox controls.

// Transform pipelines
" hello world " |> trim |> upper→ "HELLO WORLD"
// Null-safe navigation
user?.profile?.avatar ?? "default.png"→ "default.png"
// Lambda predicates
users |> filter(.age >= 18) |> map(.name)→ ["Alice"]
eval() would be recklessA pricing rule changes every quarter. With Bonsai it is a text field in your admin panel that evaluates at runtime.
order.total
>= freeShippingThreshold
&& customer.tier == "gold"Store a saved view as a string and evaluate it per row, with no custom query parser to build or maintain.
orders |> filter(
.status == "pending"
&& .total > 500
)Template expressions live alongside the copy, not buried in application code or a separate engine.
`Hi ${user.firstName},
order ${order.id} ships
${shipDate |> formatDate}`