
Syntax of .me – Simple, Powerful, and Language-Agnostic
.me is not just another state library. It's a semantic kernel that lets you define your data and logic using simple paths and algebra. You think in terms of what you want, not how to wire everything together. Quick Start import Me from " this.me " ; const me = new Me (); me [ " @ " ]( " jabellae " ); // Declare your identity me . profile . name ( " Abella " ); me . profile . bio ( " Building the semantic web. " ); me . users . ana . name ( " Ana " ); me . users . ana . age ( 22 ); me . friends . ana [ " -> " ]( " users.ana " ); // Create relationships // Automatic logic that applies to all friends me . friends [ " [i] " ][ " = " ]( " is_adult " , " age >= 18 " ); console . log ( me ( " friends.ana.is_adult " )); // → true console . log ( me ( " friends[age > 18].name " )); // → { ana: "Ana" } Core Concepts Paths are the main way to address data ( me.profile.name , me.users.ana.age ) Dot (.) creates hierarchy [] is used for indexing, filtering and broadcasting () reads or writes a value
Continue reading on Dev.to
Opens in a new tab



