libero

RPC dispatch and client stub generator.

Scans server/src/server/**/*.gleam for pub fns marked with a /// @rpc doc comment and produces:

  1. client/src/client/rpc/<module>.gleam, per-module labeled stub functions that look like ordinary Gleam functions to the client developer. Each stub takes the same labels as the server function (minus the first “session context” param) plus an on_response callback, and returns Effect(msg).

  2. server/src/server/rpc_dispatch_generated.gleam, a flat case expression that receives a decoded call envelope, looks up the function by wire name, coerces the positional args, and calls the real server function with the session context prepended.

Conventions

Values

pub fn main() -> Nil
Search Document