Skip to content
neode 1.0 alpha

Nine runnable recipes. Each one opens in the playground.

Every snippet here is the code from the repo's examples/cookbook/.

✓ All 9 recipes ran against Neo4j 5 Enterprise (Docker, :7689) in the website build on 2026-11-10.

01 crud-collection.ts Full CRUD lifecycle: find by key and elementId, list, update, Collection and toJson serialisation. Open in playground →
02 relationships.ts MERGE a relationship with edge properties, detach it, and see cascade 'delete' vs 'detach' on delete. Open in playground →
03 eager-read-models.ts Eager chains hydrated to depth, and @RelatedOne / @RelatedMany / @RelationshipCount projections in one query. Open in playground →
04 validation.ts Zod-powered rules on properties; every failing check collected into one ValidationError before the write. Open in playground →
05 schema-sync.ts installSchema() creates declared constraints and indexes; schemaDiff() reports drift; dropSchema() reverses. Open in playground →
06 search-fulltext-vector.ts Full-text search with relevance scores and k-nearest-neighbour vector search over declared indexes. Open in playground →
07 batch-and-transactions.ts All-or-nothing batches with per-statement errors, and explicit transactions that commit or roll back as one. Open in playground →
08 multi-database.ts A default database plus per-call overrides — write an audit copy of a node to another database. Open in playground →
09 server-startup.ts The startup sequence every service wants: waitUntilReachable(), fromEnv(), installSchema(), then serve. Open in playground →