mix mishka.ui.gen.mob.kit (Mishka Chelekom v0.0.10)

Copy Markdown View Source

Vendor the shared Mob support modules (Anchored, Event, Color) into your app

Mob components share two support modules that are not Chelekom components — nobody generates event by name:

  • Event — widens a bare event tag into the {screen_pid, tag} the renderer registers. A handler prop that skips this serialises as an ordinary prop and the control renders perfectly and does nothing, which is the single easiest mistake to make in a Mob component.
  • Color — hex parsing, HSV↔RGB and ARGB packing, used by the colour controls.

They are vendored once, into lib/<app>/components/, and are never module-prefixed: a prefix distinguishes your components from someone else's, and these are neither — they are the shared floor both stand on.

Run this before generating any component. mix mishka.ui.gen.mob composes it for you when a component needs it, so you rarely run it by hand.

Example

mix mishka.ui.gen.mob.kit

Options

  • --only - Comma-separated kit modules, instead of all of them
  • --module-prefix - Not applied to the kit modules themselves, but their docs reference components, and those follow the prefix
  • --yes - Apply without prompts

Summary

Functions

igniter(igniter)

Callback implementation for Igniter.Mix.Task.igniter/1.