Guides
Looks like TS for onboarding cost ≈ 0 — but Poi is a standalone language. Semantics diverge; there is no TS source on either side of a .poi file.
| Construct | Example |
|---|---|
| Functions / arrows | function f(a) { return a } · (a) => a |
| Bindings | const x = 1 · let y = 1 (let is reactive in functions) |
| Types | type T = { a: string } · unions · arrays |
| Modules | import { x } from "./foo.poi" · export const … |
| JSX | Components return JSX; runtime re-renders on reactive reads |
Module-level reactive aggregate: fields, get derived, methods as actions.
Exhaustive pattern matching over sums and literal unions. Preferred over nested if/else for state machines.
email?: string on a type field is Option sugar. Dereference only after narrow.
No ===/!==. Equality is the Poi deep operator.
Use == / !=. Optional chaining and nullish coalescing are parse errors — use match / Option.
Authoritative: docs/01-syntax.md · living corpus: src/reference/cheatsheet.poi.