API Reference mob_ash v#0.1.1

Copy Markdown View Source

Modules

Resource-driven Mob screens from Ash.

Shared parameterized detail screen: Ash.get!/2 of the route-bound :resource by :id, one labelled row per display attribute, plus Delete (Ash.destroy!/1 → pop).

Shared parameterized create form: one <TextField> per writable scalar attribute of the route-bound :resource; Create runs the resource's primary create action via Ash.create!/1 and pops back.

Spec-v2 screens generator: runs at BUILD time inside the host project (under mob_dev's host-config audit) and emits three route entries per Ash resource, each pointing at a shared parameterized screen with the resource module as route-bound :params (delivered to mount/3 by core navigation).

Pure Ash-introspection helpers the generator and the shared screens build on. Kept public + side-effect free so the resource→UI mapping is unit- testable without a device (and without mob_dev).

Shared parameterized list screen: reads every record of the route-bound :resource via Ash.read!/1 and renders one tappable row per record (tap → detail). The :resource arrives in mount/3 params either from the generated route (route-bound params) or MobAsh.navigate/3.